From 346f73bb1d29f589509a35175c8f2d27b5b18b0f Mon Sep 17 00:00:00 2001 From: "J. Ryan Stinnett" Date: Thu, 31 Jan 2019 10:01:31 -0600 Subject: [PATCH] Remove dead code tweaking server URLs on blur --- src/components/views/auth/ModularServerConfig.js | 2 -- src/components/views/auth/ServerConfig.js | 4 ---- 2 files changed, 6 deletions(-) diff --git a/src/components/views/auth/ModularServerConfig.js b/src/components/views/auth/ModularServerConfig.js index 61bfba1125..9c6c4b01bf 100644 --- a/src/components/views/auth/ModularServerConfig.js +++ b/src/components/views/auth/ModularServerConfig.js @@ -79,8 +79,6 @@ export default class ModularServerConfig extends React.PureComponent { onHomeserverBlur = (ev) => { this._hsTimeoutId = this._waitThenInvoke(this._hsTimeoutId, () => { - let hsUrl = this.state.hsUrl.trim().replace(/\/$/, ""); - if (hsUrl === "") hsUrl = this.props.defaultHsUrl; this.props.onServerConfigChange({ hsUrl: this.state.hsUrl, isUrl: this.props.defaultIsUrl, diff --git a/src/components/views/auth/ServerConfig.js b/src/components/views/auth/ServerConfig.js index d90e2c36b5..cb0e0dc38e 100644 --- a/src/components/views/auth/ServerConfig.js +++ b/src/components/views/auth/ServerConfig.js @@ -78,8 +78,6 @@ export default class ServerConfig extends React.PureComponent { onHomeserverBlur = (ev) => { this._hsTimeoutId = this._waitThenInvoke(this._hsTimeoutId, () => { - let hsUrl = this.state.hsUrl.trim().replace(/\/$/, ""); - if (hsUrl === "") hsUrl = this.props.defaultHsUrl; this.props.onServerConfigChange({ hsUrl: this.state.hsUrl, isUrl: this.state.isUrl, @@ -94,8 +92,6 @@ export default class ServerConfig extends React.PureComponent { onIdentityServerBlur = (ev) => { this._isTimeoutId = this._waitThenInvoke(this._isTimeoutId, () => { - let isUrl = this.state.isUrl.trim().replace(/\/$/, ""); - if (isUrl === "") isUrl = this.props.defaultIsUrl; this.props.onServerConfigChange({ hsUrl: this.state.hsUrl, isUrl: this.state.isUrl,