--- a/client/src/api/APIClient.js Thu Aug 03 09:44:37 2017 +0200
+++ b/client/src/api/APIClient.js Thu Aug 03 17:33:00 2017 +0200
@@ -1,4 +1,5 @@
import qs from 'qs';
+import { getToken, getClientId } from '../selectors/authSelectors'
class APIClient {
constructor(baseURL) {
@@ -40,12 +41,12 @@
getToken = () => {
const state = this.store.getState();
- return state.getIn(['authStatus', 'token']);
+ return getToken(state);
}
getClientId = () => {
const state = this.store.getState();
- return state.getIn(['authStatus', 'clientId']);
+ return getClientId(state);
}
hasToken = () => {