Changeset d0ef259 for pages/api/poker
- Timestamp:
- 07/12/22 00:13:20 (2 years ago)
- Branches:
- main
- Children:
- e9f11ac
- Parents:
- 95ce58b
- File:
-
- 1 edited
Legend:
- Unmodified
- Added
- Removed
-
pages/api/poker/index.js
r95ce58b rd0ef259 256 256 /** 257 257 * /---------------------- GET ----------------------/ 258 * Creates the table and enters the user inside258 * Updates the state periodically 259 259 * @action update_state 260 260 * @param session_id … … 265 265 const { success, table, player } = getTableAndPlayer(session_id); 266 266 267 if ( table.started && !table.ended) {267 if (success && table.started && !table.ended) { 268 268 const d = Date.now(); 269 269 … … 272 272 table.players[table.turnIdx].isFolded = true; 273 273 274 table.lastActivity = Date.now(); 274 275 setNextPlayerIdx(table.id); 275 276 }
Note:
See TracChangeset
for help on using the changeset viewer.