From dbd148489d0bc38d98e10792a38da37afc3f9e3a Mon Sep 17 00:00:00 2001 From: Michael Telatynski <7t3chguy@gmail.com> Date: Mon, 29 Nov 2021 11:06:11 +0000 Subject: [PATCH] Hide server options hint when disable_custom_urls is true (#7215) --- src/components/views/elements/ServerPicker.tsx | 6 ++++-- 1 file changed, 4 insertions(+), 2 deletions(-) diff --git a/src/components/views/elements/ServerPicker.tsx b/src/components/views/elements/ServerPicker.tsx index 5e6ef62504..51b18ac6c2 100644 --- a/src/components/views/elements/ServerPicker.tsx +++ b/src/components/views/elements/ServerPicker.tsx @@ -53,8 +53,10 @@ const onHelpClick = () => { }; const ServerPicker = ({ title, dialogTitle, serverConfig, onServerConfigChange }: IProps) => { + const disableCustomUrls = SdkConfig.get()["disable_custom_urls"]; + let editBtn; - if (!SdkConfig.get()["disable_custom_urls"] && onServerConfigChange) { + if (!disableCustomUrls && onServerConfigChange) { const onClick = () => { showPickerDialog(dialogTitle, serverConfig, (config?: ValidatedServerConfig) => { if (config) { @@ -83,7 +85,7 @@ const ServerPicker = ({ title, dialogTitle, serverConfig, onServerConfigChange } return