diff options
author | Tor Andersson <tor@ccxvii.net> | 2021-07-10 00:02:41 +0200 |
---|---|---|
committer | Tor Andersson <tor@ccxvii.net> | 2021-07-10 00:03:20 +0200 |
commit | 9f8cec0889c79d9ead6d077077634754761a8dc1 (patch) | |
tree | a021774c126ce7bffd7a4bfedf9fe13283a5be7a /server.js | |
parent | 3cdbf22caefe5c8bff07b01abb8b70c4ff6b2bb1 (diff) | |
download | server-9f8cec0889c79d9ead6d077077634754761a8dc1.tar.gz |
Fix mail notifications when active goes from Both to specific.
Diffstat (limited to 'server.js')
-rw-r--r-- | server.js | 4 |
1 files changed, 2 insertions, 2 deletions
@@ -1054,7 +1054,7 @@ function mail_your_turn_notification_to_offline_users(game_id, old_active, new_a let users = {}; let online = {}; for (let p of QUERY_PLAYERS_FULL.all(game_id)) { - if (p.notifications && !is_active(old_active, p.role) && is_active(new_active, p.role)) { + if (p.notifications && is_active(new_active, p.role)) { users[p.user_id] = p; if (is_online(game_id, p.user_id)) online[p.user_id] = 1; @@ -1065,7 +1065,7 @@ function mail_your_turn_notification_to_offline_users(game_id, old_active, new_a if (online[u]) reset_your_turn_notification(users[u], game_id); else - mail_your_turn_notification(users[u], game_id, '+1 minute'); + mail_your_turn_notification(users[u], game_id, '+0 seconds'); } } |