diff options
| author | Oskar Nyberg <oskar@mullvad.net> | 2021-07-23 13:39:34 +0200 |
|---|---|---|
| committer | Oskar Nyberg <oskar@mullvad.net> | 2021-07-23 13:39:34 +0200 |
| commit | c2acb4aff58b7b7f60a13ab05104910f70741e3c (patch) | |
| tree | bc8bcac2c7386aa2522c89223aba4471cfb27820 /gui/src/renderer/containers | |
| parent | d0951f1f9ae8d0c6be9c4aa961a257c97ddbf4f5 (diff) | |
| parent | f5f870074496283521d6adcc80537a54e2168c8e (diff) | |
| download | mullvadvpn-c2acb4aff58b7b7f60a13ab05104910f70741e3c.tar.xz mullvadvpn-c2acb4aff58b7b7f60a13ab05104910f70741e3c.zip | |
Merge branch 'fix-linter-warnings'
Diffstat (limited to 'gui/src/renderer/containers')
| -rw-r--r-- | gui/src/renderer/containers/AccountPage.tsx | 3 | ||||
| -rw-r--r-- | gui/src/renderer/containers/LoginPage.tsx | 5 | ||||
| -rw-r--r-- | gui/src/renderer/containers/PreferencesPage.tsx | 5 | ||||
| -rw-r--r-- | gui/src/renderer/containers/SupportPage.tsx | 3 |
4 files changed, 6 insertions, 10 deletions
diff --git a/gui/src/renderer/containers/AccountPage.tsx b/gui/src/renderer/containers/AccountPage.tsx index 8751107c74..641374c504 100644 --- a/gui/src/renderer/containers/AccountPage.tsx +++ b/gui/src/renderer/containers/AccountPage.tsx @@ -1,6 +1,5 @@ import { connect } from 'react-redux'; import { links } from '../../config.json'; -import consumePromise from '../../shared/promise'; import Account from '../components/Account'; import withAppContext, { IAppContext } from '../context'; @@ -16,7 +15,7 @@ const mapStateToProps = (state: IReduxState) => ({ const mapDispatchToProps = (_dispatch: ReduxDispatch, props: IHistoryProps & IAppContext) => { return { onLogout: () => { - consumePromise(props.app.logout()); + void props.app.logout(); }, onClose: () => { props.history.pop(); diff --git a/gui/src/renderer/containers/LoginPage.tsx b/gui/src/renderer/containers/LoginPage.tsx index a56e6ec04a..6797f40d3e 100644 --- a/gui/src/renderer/containers/LoginPage.tsx +++ b/gui/src/renderer/containers/LoginPage.tsx @@ -1,6 +1,5 @@ import { connect } from 'react-redux'; import { bindActionCreators } from 'redux'; -import consumePromise from '../../shared/promise'; import Login from '../components/Login'; import withAppContext, { IAppContext } from '../context'; import accountActions from '../redux/account/actions'; @@ -18,7 +17,7 @@ const mapDispatchToProps = (dispatch: ReduxDispatch, props: IAppContext) => { const { resetLoginError, updateAccountToken } = bindActionCreators(accountActions, dispatch); return { login: (account: string) => { - consumePromise(props.app.login(account)); + void props.app.login(account); }, resetLoginError: () => { resetLoginError(); @@ -26,7 +25,7 @@ const mapDispatchToProps = (dispatch: ReduxDispatch, props: IAppContext) => { openExternalLink: (url: string) => props.app.openUrl(url), updateAccountToken, clearAccountHistory: () => props.app.clearAccountHistory(), - createNewAccount: () => consumePromise(props.app.createNewAccount()), + createNewAccount: () => void props.app.createNewAccount(), }; }; diff --git a/gui/src/renderer/containers/PreferencesPage.tsx b/gui/src/renderer/containers/PreferencesPage.tsx index 671ba33c26..a050afedf7 100644 --- a/gui/src/renderer/containers/PreferencesPage.tsx +++ b/gui/src/renderer/containers/PreferencesPage.tsx @@ -1,7 +1,6 @@ import { connect } from 'react-redux'; import { IDnsOptions } from '../../shared/daemon-rpc-types'; import log from '../../shared/logging'; -import consumePromise from '../../shared/promise'; import Preferences from '../components/Preferences'; import withAppContext, { IAppContext } from '../context'; import { IHistoryProps, withHistory } from '../lib/history'; @@ -39,10 +38,10 @@ const mapDispatchToProps = (_dispatch: ReduxDispatch, props: IHistoryProps & IAp props.app.setAutoConnect(autoConnect); }, setAllowLan: (allowLan: boolean) => { - consumePromise(props.app.setAllowLan(allowLan)); + void props.app.setAllowLan(allowLan); }, setShowBetaReleases: (showBetaReleases: boolean) => { - consumePromise(props.app.setShowBetaReleases(showBetaReleases)); + void props.app.setShowBetaReleases(showBetaReleases); }, setStartMinimized: (startMinimized: boolean) => { props.app.setStartMinimized(startMinimized); diff --git a/gui/src/renderer/containers/SupportPage.tsx b/gui/src/renderer/containers/SupportPage.tsx index a4bdbd4ac3..8457d6f6ff 100644 --- a/gui/src/renderer/containers/SupportPage.tsx +++ b/gui/src/renderer/containers/SupportPage.tsx @@ -1,6 +1,5 @@ import { connect } from 'react-redux'; import { bindActionCreators } from 'redux'; -import consumePromise from '../../shared/promise'; import Support from '../components/Support'; import withAppContext, { IAppContext } from '../context'; import { IHistoryProps, withHistory } from '../lib/history'; @@ -24,7 +23,7 @@ const mapDispatchToProps = (dispatch: ReduxDispatch, props: IAppContext & IHisto props.history.pop(); }, viewLog(id: string) { - consumePromise(props.app.viewLog(id)); + void props.app.viewLog(id); }, saveReportForm, clearReportForm, |
