From 4f91375cb291eb1618bfb704dd09b393f3b7a5da Mon Sep 17 00:00:00 2001 From: Alireza Ahmadi Date: Wed, 1 Mar 2023 19:52:21 +0100 Subject: [PATCH] Small fixes --- web/controller/inbound.go | 2 -- web/html/xui/inbounds.html | 2 +- 2 files changed, 1 insertion(+), 3 deletions(-) diff --git a/web/controller/inbound.go b/web/controller/inbound.go index 0add17a1..904e88a1 100644 --- a/web/controller/inbound.go +++ b/web/controller/inbound.go @@ -154,8 +154,6 @@ func (a *InboundController) delInboundClient(c *gin.Context) { return } - logger.Error("email: " + email + " ID: " + strconv.Itoa(inbound.Id) + " Settings: " + inbound.Settings) - err = a.inboundService.DelInboundClient(inbound, email) if err != nil { jsonMsg(c, "something worng!", err) diff --git a/web/html/xui/inbounds.html b/web/html/xui/inbounds.html index 514fed52..b06e2da6 100644 --- a/web/html/xui/inbounds.html +++ b/web/html/xui/inbounds.html @@ -499,7 +499,7 @@ isTrafficExhausted(dbInbound, email) { if(email.length == 0) return false clientStats = dbInbound.clientStats.find(stats => stats.email === email) - return clientStats.down + clientStats.up > clientStats.total + return clientStats ? clientStats.down + clientStats.up > clientStats.total : false }, isClientEnabled(dbInbound, email) { clientStats = dbInbound.clientStats ? dbInbound.clientStats.find(stats => stats.email === email) : null