summaryrefslogtreecommitdiffhomepage
path: root/gui/src/renderer
diff options
context:
space:
mode:
authorJanito Vaqueiro Ferreira Filho <janito@mullvad.net>2019-06-27 20:25:45 +0000
committerJanito Vaqueiro Ferreira Filho <janito@mullvad.net>2019-06-28 19:18:45 +0000
commitd91a855e6b7981e90f7cd9f6d2374dcb54cd04bb (patch)
treee3d66089e74e9414b7624e414f28efa1ab14a9a3 /gui/src/renderer
parentea3466c3bf5eb16619d67bd61e27d635d879c51b (diff)
downloadmullvadvpn-d91a855e6b7981e90f7cd9f6d2374dcb54cd04bb.tar.xz
mullvadvpn-d91a855e6b7981e90f7cd9f6d2374dcb54cd04bb.zip
Change how tunnel endpoint is broadcasted
Diffstat (limited to 'gui/src/renderer')
-rw-r--r--gui/src/renderer/containers/ConnectionPanelContainer.tsx4
-rw-r--r--gui/src/renderer/redux/connection/actions.ts14
-rw-r--r--gui/src/renderer/redux/connection/reducers.ts4
3 files changed, 11 insertions, 11 deletions
diff --git a/gui/src/renderer/containers/ConnectionPanelContainer.tsx b/gui/src/renderer/containers/ConnectionPanelContainer.tsx
index 77b164c65b..44d3330c78 100644
--- a/gui/src/renderer/containers/ConnectionPanelContainer.tsx
+++ b/gui/src/renderer/containers/ConnectionPanelContainer.tsx
@@ -43,12 +43,12 @@ const mapStateToProps = (state: IReduxState) => {
const inAddress: IInAddress | undefined =
(status.state === 'connecting' || status.state === 'connected') && status.details
- ? tunnelEndpointToRelayInAddress(status.details)
+ ? tunnelEndpointToRelayInAddress(status.details.endpoint)
: undefined;
const bridgeInfo: IBridgeData | undefined =
(status.state === 'connecting' || status.state === 'connected') && status.details
- ? tunnelEndpointToBridgeData(status.details)
+ ? tunnelEndpointToBridgeData(status.details.endpoint)
: undefined;
return {
diff --git a/gui/src/renderer/redux/connection/actions.ts b/gui/src/renderer/redux/connection/actions.ts
index b84e85f8e6..8f5b2e62bb 100644
--- a/gui/src/renderer/redux/connection/actions.ts
+++ b/gui/src/renderer/redux/connection/actions.ts
@@ -2,17 +2,17 @@ import {
AfterDisconnect,
BlockReason,
ILocation,
- ITunnelEndpoint,
+ ITunnelStateRelayInfo,
} from '../../../shared/daemon-rpc-types';
interface IConnectingAction {
type: 'CONNECTING';
- tunnelEndpoint?: ITunnelEndpoint;
+ details?: ITunnelStateRelayInfo;
}
interface IConnectedAction {
type: 'CONNECTED';
- tunnelEndpoint: ITunnelEndpoint;
+ details: ITunnelStateRelayInfo;
}
interface IDisconnectedAction {
@@ -48,17 +48,17 @@ export type ConnectionAction =
| IBlockedAction
| IUpdateBlockStateAction;
-function connecting(tunnelEndpoint?: ITunnelEndpoint): IConnectingAction {
+function connecting(details?: ITunnelStateRelayInfo): IConnectingAction {
return {
type: 'CONNECTING',
- tunnelEndpoint,
+ details,
};
}
-function connected(tunnelEndpoint: ITunnelEndpoint): IConnectedAction {
+function connected(details: ITunnelStateRelayInfo): IConnectedAction {
return {
type: 'CONNECTED',
- tunnelEndpoint,
+ details,
};
}
diff --git a/gui/src/renderer/redux/connection/reducers.ts b/gui/src/renderer/redux/connection/reducers.ts
index 8b971cb7cc..4772df8fc5 100644
--- a/gui/src/renderer/redux/connection/reducers.ts
+++ b/gui/src/renderer/redux/connection/reducers.ts
@@ -41,13 +41,13 @@ export default function(
case 'CONNECTING':
return {
...state,
- status: { state: 'connecting', details: action.tunnelEndpoint },
+ status: { state: 'connecting', details: action.details },
};
case 'CONNECTED':
return {
...state,
- status: { state: 'connected', details: action.tunnelEndpoint },
+ status: { state: 'connected', details: action.details },
};
case 'DISCONNECTED':