diff options
| author | Shishkevich D. <135337715+shishkevichd@users.noreply.github.com> | 2025-06-05 14:12:06 +0300 |
|---|---|---|
| committer | GitHub <noreply@github.com> | 2025-06-05 14:12:06 +0300 |
| commit | 1781790dce2935c169c9663e74534071fcd28fc8 (patch) | |
| tree | 13ddc10e4df043705897299debca18f0969d02b6 /web | |
| parent | 29f950046acfcb5d9c601aa7f484bb3bde0849dc (diff) | |
fix: don't show ip limit for some protocols (#3064)
this causes the modal window to fail because protocols like wireguard, dokodemo and so on do not have clients (like vless/vmess, shadowsocks, etc).
Diffstat (limited to 'web')
| -rw-r--r-- | web/html/modals/inbound_info_modal.html | 17 |
1 files changed, 13 insertions, 4 deletions
diff --git a/web/html/modals/inbound_info_modal.html b/web/html/modals/inbound_info_modal.html index 0ccaeff0..9da3fc86 100644 --- a/web/html/modals/inbound_info_modal.html +++ b/web/html/modals/inbound_info_modal.html @@ -478,10 +478,19 @@ this.isExpired = this.inbound.clients ? this.inbound.isExpiry(index) : this.dbInbound.isExpiry; this.clientStats = this.inbound.clients ? this.dbInbound.clientStats.find(row => row.email === this.clientSettings.email) : []; - if (app.ipLimitEnable && this.clientSettings.limitIp) { - refreshIPs(this.clientStats.email).then((ips) => { - this.clientIps = ips; - }) + if ( + [ + Protocols.VMESS, + Protocols.VLESS, + Protocols.TROJAN, + Protocols.SHADOWSOCKS + ].includes(this.inbound.protocol) + ) { + if (app.ipLimitEnable && this.clientSettings.limitIp) { + refreshIPs(this.clientStats.email).then((ips) => { + this.clientIps = ips; + }) + } } if (this.inbound.protocol == Protocols.WIREGUARD) { this.links = this.inbound.genInboundLinks(dbInbound.remark).split('\r\n') |
