Skip to content

Commit

Permalink
Change nomenclature of error message room -> game
Browse files Browse the repository at this point in the history
  • Loading branch information
JordanPawlett committed May 9, 2020
1 parent da28ffc commit cfeaad0
Show file tree
Hide file tree
Showing 2 changed files with 3 additions and 2 deletions.
2 changes: 1 addition & 1 deletion services/rooms-service/src/rooms-service.ts
Original file line number Diff line number Diff line change
Expand Up @@ -314,7 +314,7 @@ export default class RoomsService extends Service {
return Promise.resolve(room);
} else {
// user must be in another room.
throw forbidden('You are already in a room.');
throw forbidden('You are already in a game.');
}
}

Expand Down
3 changes: 2 additions & 1 deletion services/websocket-gateway-service/src/DefaultNamespace.ts
Original file line number Diff line number Diff line change
Expand Up @@ -34,7 +34,8 @@ export default class DefaultNamespace extends BaseNamespace {
if (user.socket === client.id && user.disconnectedAt && afterTimeoutTime - user.disconnectedAt > (timeout - 5000)) {
this.broker.emit('websocket-gateway.client.disconnected', { _id });
}
});
})
.catch(() => this.broker.emit('websocket-gateway.client.disconnected', { _id }));
}, timeout);
})
// If error, client must have logged out.
Expand Down

0 comments on commit cfeaad0

Please sign in to comment.