Compare commits

...

2 Commits

Author SHA1 Message Date
Niels Simenon 50263b2b56 1.23.2 2022-11-26 16:49:31 +01:00
Niels Simenon 87f2e81794 Fixed checking username on non-existent user. 2022-11-26 16:49:29 +01:00
3 changed files with 4 additions and 4 deletions

4
package-lock.json generated
View File

@ -1,12 +1,12 @@
{
"name": "schat2-clive",
"version": "1.23.1",
"version": "1.23.2",
"lockfileVersion": 2,
"requires": true,
"packages": {
"": {
"name": "schat2-clive",
"version": "1.23.1",
"version": "1.23.2",
"license": "ISC",
"dependencies": {
"bhttp": "^1.2.8",

View File

@ -1,6 +1,6 @@
{
"name": "schat2-clive",
"version": "1.23.1",
"version": "1.23.2",
"description": "Game host for SChat 2-powered chat sites",
"main": "src/app.js",
"scripts": {

View File

@ -243,7 +243,7 @@ function onMessage(message, bot, games) {
}
}
if (message.type === 'message' && user.username !== config.user.username) {
if (message.type === 'message' && user?.username !== config.user.username) {
Object.values(Object.fromEntries(Object.values(games).map((game) => [game.key, game]))).forEach((game) => game.onMessage?.(message, {
...game,
bot,