From 15605b9918047498c32362eeaf6ba62ccf2dc095 Mon Sep 17 00:00:00 2001 From: Alexis Hovorka Date: Sat, 19 Feb 2022 23:39:39 -0700 Subject: [feat] First playable --- app.js | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) (limited to 'app.js') diff --git a/app.js b/app.js index 97e8c9b..7b5f25c 100644 --- a/app.js +++ b/app.js @@ -30,7 +30,7 @@ app.get("/guess/(?[a-z]*)", cors((req, res, match) => { match.word.split("").map(c => findAll(c, today())) .map((c,i,a) => c.length === 0? " " : c.includes(i)? "=" : c) .map((c,i,a) => Array.isArray(c)? c.filter(e => a[e] !== "=") : c) - .reduce((a,c) => Array.isArray(c)? a+(c.find(e => !a.includes(e))||" ") : a+c, "") + .reduce((a,c) => Array.isArray(c)? a+(c.find(e => !a.includes(e))??" ") : a+c, "") .replace(/[0-9]/g, "-"); sj(res, {word: match.word, result}); -- cgit v1.2.3-70-g09d2