From 72df05a403e2c2c0126e939a1fb8dc3a9fb0c5b9 Mon Sep 17 00:00:00 2001 From: mrchatam Date: Sat, 12 Sep 2026 13:23:06 +0330 Subject: [PATCH] fix(hosts): keep TLS override fields visible when Security is same (#6452) When Security is same, Fingerprint/SNI and TLS extras stayed live in form state but were hidden, so stale values could not be cleared (#6444). --- frontend/src/pages/hosts/HostFormModal.tsx | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/frontend/src/pages/hosts/HostFormModal.tsx b/frontend/src/pages/hosts/HostFormModal.tsx index 21810c02c..5561ce1d0 100644 --- a/frontend/src/pages/hosts/HostFormModal.tsx +++ b/frontend/src/pages/hosts/HostFormModal.tsx @@ -91,8 +91,8 @@ export default function HostFormModal({ const [loading, setLoading] = useState(false); const security = (useWatch({ control: methods.control, name: 'security' }) ?? 'same') as string; - const showTls = security === 'tls' || security === 'reality'; - const showTlsExtras = security === 'tls'; + const showTls = security === 'tls' || security === 'reality' || security === 'same'; + const showTlsExtras = security === 'tls' || security === 'same'; // React resets this during render rather than in an effect so the modal's // first open frame already shows cleared fields.