diff --git a/packages/play-node-go/play-node-go/src/reducers/init/stateReducer.init.js b/packages/play-node-go/play-node-go/src/reducers/init/stateReducer.init.js index 33e66f1..5a396fa 100644 --- a/packages/play-node-go/play-node-go/src/reducers/init/stateReducer.init.js +++ b/packages/play-node-go/play-node-go/src/reducers/init/stateReducer.init.js @@ -5,13 +5,22 @@ const socket = require('../../io'); export const initState = (): state => { return { - user: {}, + user: { username: '', email: '', id: 0 }, errors: {}, - currentRoom: {}, - messages: {}, - games: {}, + currentRoom: { description: '', id: 0, language: '', name: '' }, + messages: [ { + admin: false, content: '', username: '' + } ], + games: [ { + boardSize: 0, handicap: 0, id: 0, komi: 0.0, open: false, + playerBlack: '', playerBlackRank: '', playerWhite: '', + playerWhiteRank: '', winType: null + } ], joinGame: {}, - socket: {}, - connect: {} + socket: { + connected: false, + nsp: '' + }, + connect: { location: '', type: '' } }; } \ No newline at end of file