diff options
author | Julien Dessaux | 2023-01-03 23:51:00 +0100 |
---|---|---|
committer | Julien Dessaux | 2023-01-03 23:51:00 +0100 |
commit | c5d2d7ca77a502ea607d2db5ecdec972bc76bc69 (patch) | |
tree | 877c4bb29aef5ba8de491d78cfc9ee7e31232ad7 /controllers | |
parent | Continue adding tests (diff) | |
download | jeux-de-mots-c5d2d7ca77a502ea607d2db5ecdec972bc76bc69.tar.gz jeux-de-mots-c5d2d7ca77a502ea607d2db5ecdec972bc76bc69.tar.bz2 jeux-de-mots-c5d2d7ca77a502ea607d2db5ecdec972bc76bc69.zip |
Fixed fixtures and testing
Diffstat (limited to 'controllers')
-rw-r--r-- | controllers/games/root.js | 4 |
1 files changed, 1 insertions, 3 deletions
diff --git a/controllers/games/root.js b/controllers/games/root.js index 0483f55..4a4e80d 100644 --- a/controllers/games/root.js +++ b/controllers/games/root.js @@ -19,9 +19,7 @@ function makePageData(user) { export function root_get(req, res) { let page = makePageData(req.session.user); - for (let i=0; i<page.games.length; i++) { - page.games[i].data = JSON.parse(page.games[i].data); - } + page.games.forEach(g => g.data = JSON.parse(g.data)); return res.render("games", page); } |