diff options
author | Tor Andersson <tor@ccxvii.net> | 2021-07-07 16:29:19 +0200 |
---|---|---|
committer | Tor Andersson <tor@ccxvii.net> | 2021-07-07 16:29:19 +0200 |
commit | 51dc768d9daa7216fede2ac7eb9bfd4643d77a52 (patch) | |
tree | 9115576d80d54d1f353f4df5288b4f81d6ab6d61 | |
parent | e1ba80b1b7561f50c71d4ec45912eb39f438b511 (diff) | |
download | server-51dc768d9daa7216fede2ac7eb9bfd4643d77a52.tar.gz |
Add missing 'return' statement.
-rw-r--r-- | server.js | 2 |
1 files changed, 1 insertions, 1 deletions
@@ -944,7 +944,7 @@ app.get('/play/:game_id', must_be_logged_in, function (req, res) { return res.redirect('/join/'+game_id); let role = QUERY_ROLE_FROM_GAME_AND_USER.get(game_id, user_id); if (!role) - res.redirect('/'+title+'/play.html?game='+game_id+'&role=Observer'); + return res.redirect('/'+title+'/play.html?game='+game_id+'&role=Observer'); return res.redirect('/'+title+'/play.html?game='+game_id+'&role='+role); } catch (err) { req.flash('message', err.toString()); |