summaryrefslogtreecommitdiff
path: root/frontend/src/sagas/home.js
diff options
context:
space:
mode:
authorVictor Chabbert <chabbertvi@eisti.eu>2017-08-07 23:56:23 +0200
committerVictor Chabbert <chabbertvi@eisti.eu>2017-08-07 23:56:23 +0200
commit6b9ebbfbd6fbe47900a4f2e785c550edb915669a (patch)
treebfff955ecd3fe675c679b905359326792a526ab3 /frontend/src/sagas/home.js
parentRemove unnecessary selector (diff)
downloadseven-wonders-6b9ebbfbd6fbe47900a4f2e785c550edb915669a.tar.gz
seven-wonders-6b9ebbfbd6fbe47900a4f2e785c550edb915669a.tar.bz2
seven-wonders-6b9ebbfbd6fbe47900a4f2e785c550edb915669a.zip
Fix flow errors
Diffstat (limited to 'frontend/src/sagas/home.js')
-rw-r--r--frontend/src/sagas/home.js5
1 files changed, 3 insertions, 2 deletions
diff --git a/frontend/src/sagas/home.js b/frontend/src/sagas/home.js
index a6f19565..89271706 100644
--- a/frontend/src/sagas/home.js
+++ b/frontend/src/sagas/home.js
@@ -1,7 +1,7 @@
// @flow
import { push } from 'react-router-redux';
import { eventChannel } from 'redux-saga';
-import { apply, call, put, take } from 'redux-saga/effects';
+import { apply, call, put, take, all } from 'redux-saga/effects';
import type { ApiPlayer } from '../api/model';
import type { SevenWondersSession } from '../api/sevenWondersApi';
@@ -10,6 +10,7 @@ import { actions, types } from '../redux/players';
function* sendUsername(session: SevenWondersSession): * {
while (true) {
const { username } = yield take(types.REQUEST_CHOOSE_USERNAME);
+ // $FlowFixMe
yield apply(session, session.chooseName, [username]);
}
}
@@ -25,7 +26,7 @@ function* validateUsername(session: SevenWondersSession): * {
}
function* homeSaga(session: SevenWondersSession): * {
- yield [call(sendUsername, session), call(validateUsername, session)];
+ yield all([call(sendUsername, session), call(validateUsername, session)]);
}
export default homeSaga;
bgstack15