From d5c532c64f1b068cb6baa7c34698059c1abcb8d9 Mon Sep 17 00:00:00 2001 From: Alireza Ahmadi Date: Sat, 9 Aug 2025 16:07:33 +0200 Subject: fix saving sockopt --- web/html/inbounds.html | 12 ++++++++++-- 1 file changed, 10 insertions(+), 2 deletions(-) (limited to 'web/html') diff --git a/web/html/inbounds.html b/web/html/inbounds.html index e2b98d49..58d2d07a 100644 --- a/web/html/inbounds.html +++ b/web/html/inbounds.html @@ -1119,7 +1119,11 @@ protocol: inbound.protocol, settings: inbound.settings.toString(), }; - if (inbound.canEnableStream()) data.streamSettings = inbound.stream.toString(); + if (inbound.canEnableStream()){ + data.streamSettings = inbound.stream.toString(); + } else if (inbound.stream?.sockopt) { + data.streamSettings = JSON.stringify({ sockopt: inbound.stream.sockopt.toJson() }, null, 2); + } data.sniffing = inbound.sniffing.toString(); data.allocate = inbound.allocate.toString(); @@ -1139,7 +1143,11 @@ protocol: inbound.protocol, settings: inbound.settings.toString(), }; - if (inbound.canEnableStream()) data.streamSettings = inbound.stream.toString(); + if (inbound.canEnableStream()){ + data.streamSettings = inbound.stream.toString(); + } else if (inbound.stream?.sockopt) { + data.streamSettings = JSON.stringify({ sockopt: inbound.stream.sockopt.toJson() }, null, 2); + } data.sniffing = inbound.sniffing.toString(); data.allocate = inbound.allocate.toString(); -- cgit v1.2.3