diff options
| author | Andrej Mihajlov <and@mullvad.net> | 2017-11-17 10:46:53 +0100 |
|---|---|---|
| committer | Andrej Mihajlov <and@mullvad.net> | 2017-11-21 16:12:59 +0100 |
| commit | 489a47a2f68194daee05e24cced6ca670c3978a0 (patch) | |
| tree | 5db85abba5e69dcf227b87bfa476bd8d22165770 /app/lib | |
| parent | 3ca41569b1d61444d4a2bf0a0dc330fbc86435ca (diff) | |
| download | mullvadvpn-489a47a2f68194daee05e24cced6ca670c3978a0.tar.xz mullvadvpn-489a47a2f68194daee05e24cced6ca670c3978a0.zip | |
Refine flow types across project
Diffstat (limited to 'app/lib')
| -rw-r--r-- | app/lib/backend.js | 5 |
1 files changed, 2 insertions, 3 deletions
diff --git a/app/lib/backend.js b/app/lib/backend.js index fe828ba6c8..fc2348961a 100644 --- a/app/lib/backend.js +++ b/app/lib/backend.js @@ -11,10 +11,9 @@ import { push } from 'react-router-redux'; import { defaultServer } from '../config'; import type { ReduxStore } from '../redux/store'; -import type { BackendState, RelayConstraintsUpdate } from './ipc-facade'; +import type { AccountToken, BackendState, RelayConstraintsUpdate } from './ipc-facade'; import type { ConnectionState } from '../redux/connection/reducers'; -export type EventType = 'connect' | 'connecting' | 'disconnect' | 'login' | 'logging' | 'logout' | 'updatedIp' | 'updatedLocation' | 'updatedReachability'; export type ErrorType = 'NO_CREDIT' | 'NO_INTERNET' | 'INVALID_ACCOUNT' | 'NO_ACCOUNT'; export type ServerInfo = { @@ -168,7 +167,7 @@ export class Backend { return (servers: ServerInfoList)[identifier]; } - login(accountToken: string): Promise<void> { + login(accountToken: AccountToken): Promise<void> { log.debug('Attempting to login with account number', accountToken); this._store.dispatch(accountActions.startLogin(accountToken)); |
