diff options
| author | Oskar Nyberg <oskar@mullvad.net> | 2020-10-14 14:49:23 +0200 |
|---|---|---|
| committer | Oskar Nyberg <oskar@mullvad.net> | 2020-10-16 11:06:43 +0200 |
| commit | 66225b84bc9d68dc7029aed34ea3781fcbb18c58 (patch) | |
| tree | 62de940469c8d2a8a1e70b4c5f2b926f3735ab71 /gui/src/renderer/components | |
| parent | d25896a3d701c0a92b4efb2ef04204480abc82ed (diff) | |
| download | mullvadvpn-66225b84bc9d68dc7029aed34ea3781fcbb18c58.tar.xz mullvadvpn-66225b84bc9d68dc7029aed34ea3781fcbb18c58.zip | |
Fix warnings from TypeScript eslint plugin after upgrade
Diffstat (limited to 'gui/src/renderer/components')
| -rw-r--r-- | gui/src/renderer/components/Connect.tsx | 4 | ||||
| -rw-r--r-- | gui/src/renderer/components/SelectLocation.tsx | 6 |
2 files changed, 5 insertions, 5 deletions
diff --git a/gui/src/renderer/components/Connect.tsx b/gui/src/renderer/components/Connect.tsx index c0c257b736..a6654ad8c0 100644 --- a/gui/src/renderer/components/Connect.tsx +++ b/gui/src/renderer/components/Connect.tsx @@ -188,8 +188,6 @@ export default class Connect extends React.Component<IProps, IState> { return HeaderBarStyle.success; case 'nothing': return HeaderBarStyle.error; - default: - throw new Error(`Invalid action after disconnection: ${status.details}`); } } } @@ -244,8 +242,6 @@ export default class Connect extends React.Component<IProps, IState> { return MarkerStyle.secure; case 'nothing': return MarkerStyle.unsecure; - default: - throw new Error(`Invalid action after disconnection: ${status.details}`); } } } diff --git a/gui/src/renderer/components/SelectLocation.tsx b/gui/src/renderer/components/SelectLocation.tsx index 52943549c6..c42994b572 100644 --- a/gui/src/renderer/components/SelectLocation.tsx +++ b/gui/src/renderer/components/SelectLocation.tsx @@ -60,7 +60,11 @@ export default class SelectLocation extends React.Component<IProps> { this.scrollToSelectedCell(); } - public componentDidUpdate(prevProps: IProps, _prevState: {}, snapshot?: ISelectLocationSnapshot) { + public componentDidUpdate( + prevProps: IProps, + _prevState: unknown, + snapshot?: ISelectLocationSnapshot, + ) { if (this.props.locationScope !== prevProps.locationScope) { this.restoreScrollPosition(this.props.locationScope); |
