X-Git-Url: https://git.cworth.org/git?p=empires-server;a=blobdiff_plain;f=empathy.js;h=7e53486d13dcd25b0c72217e7a29960de5fdd992;hp=eaf12bf8deb0a6b74d8358922643052da1afc7c2;hb=94e1835efd0f912f1a3eab7b996d86dd3137187c;hpb=3d164c48d0b979afdd83f58af9bb47e7c89c1877 diff --git a/empathy.js b/empathy.js index eaf12bf..7e53486 100644 --- a/empathy.js +++ b/empathy.js @@ -178,7 +178,7 @@ class Empathy extends Game { this.broadcast_event_object('ambiguities', this.state.ambiguities); } - receive_judging(prompt_id, session_id, word_groups) { + receive_judged(prompt_id, session_id, word_groups) { const player = this.players_by_session[session_id]; if (! player) return { valid: false, message: "Player not found" }; @@ -439,13 +439,13 @@ router.post('/end-answers/:prompt_id([0-9]+)', (request, response) => { game.perform_judging(); }); -router.post('/judging/:prompt_id([0-9]+)', (request, response) => { +router.post('/judged/:prompt_id([0-9]+)', (request, response) => { const game = request.game; const prompt_id = parseInt(request.params.prompt_id, 10); - const result = game.receive_judging(prompt_id, - request.session.id, - request.body.word_groups); + const result = game.receive_judged(prompt_id, + request.session.id, + request.body.word_groups); response.json(result); });