summaryrefslogtreecommitdiff
path: root/frontend/src/sagas/usernameChoice.js
diff options
context:
space:
mode:
authorVictor Chabbert <chabbertvi@eisti.eu>2017-01-22 12:46:01 +0100
committerVictor Chabbert <chabbertvi@eisti.eu>2017-01-22 12:46:01 +0100
commit3f2c73cccc554c87bfe39ab706bf01690fb28baf (patch)
tree2e20d1de318acbda019242a6336495c526ce110f /frontend/src/sagas/usernameChoice.js
parentAns /user/queue/lobby/joined message on game creation (diff)
downloadseven-wonders-3f2c73cccc554c87bfe39ab706bf01690fb28baf.tar.gz
seven-wonders-3f2c73cccc554c87bfe39ab706bf01690fb28baf.tar.bz2
seven-wonders-3f2c73cccc554c87bfe39ab706bf01690fb28baf.zip
Handle game browser
Diffstat (limited to 'frontend/src/sagas/usernameChoice.js')
-rw-r--r--frontend/src/sagas/usernameChoice.js2
1 files changed, 2 insertions, 0 deletions
diff --git a/frontend/src/sagas/usernameChoice.js b/frontend/src/sagas/usernameChoice.js
index 60a1a091..d0d0cdea 100644
--- a/frontend/src/sagas/usernameChoice.js
+++ b/frontend/src/sagas/usernameChoice.js
@@ -1,5 +1,6 @@
import { call, take, put } from 'redux-saga/effects'
import { eventChannel } from 'redux-saga'
+import { push } from 'react-router-redux'
import { actions, types } from '../redux/user'
@@ -21,6 +22,7 @@ function *usernameValidation({ socket }) {
const user = yield take(usernameChannel)
yield put(actions.setUsername(user.username, user.displayName, user.index))
usernameChannel.close()
+ yield put(push('/games'))
}
function *sendUsername({ socket }) {
bgstack15