added regex to delete last "/" from server url in settings dialog

This commit is contained in:
Daniel Shleifman
2021-06-14 20:36:07 +03:00
parent c62863cc02
commit 3d547133b1

View File

@@ -40,8 +40,8 @@ export default function SettingsDialog() {
.catch(() => setShow(false)) .catch(() => setShow(false))
}, [tsHost]) }, [tsHost])
const onInputHost = event => { const onInputHost = ({ target: { value } }) => {
const host = event.target.value const host = value.replace(/\/$/gi, '')
setTorrServerHost(host) setTorrServerHost(host)
setTSHost(host) setTSHost(host)
} }