From f7dbd843512d76cd2228371f3788652e97027b81 Mon Sep 17 00:00:00 2001 From: Supravisor <153783117+Supravisor@users.noreply.github.com> Date: Thu, 18 Apr 2024 19:15:05 +1200 Subject: [PATCH] fix(curriculum): update test of TODO step 6 to allow for multiple function answers (#54371) --- .../64e4e78a7ea4a168de4e6a38.md | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/curriculum/challenges/english/15-javascript-algorithms-and-data-structures-22/learn-localstorage-by-building-a-todo-app/64e4e78a7ea4a168de4e6a38.md b/curriculum/challenges/english/15-javascript-algorithms-and-data-structures-22/learn-localstorage-by-building-a-todo-app/64e4e78a7ea4a168de4e6a38.md index 9ef92baa789..555dae33a4e 100644 --- a/curriculum/challenges/english/15-javascript-algorithms-and-data-structures-22/learn-localstorage-by-building-a-todo-app/64e4e78a7ea4a168de4e6a38.md +++ b/curriculum/challenges/english/15-javascript-algorithms-and-data-structures-22/learn-localstorage-by-building-a-todo-app/64e4e78a7ea4a168de4e6a38.md @@ -40,7 +40,7 @@ assert.match(code, /openTaskFormBtn\.addEventListener\(\s*('|"|`)click\1/) Your event listener's callback function should use the `classList.toggle()` method to toggle the `hidden` class on the `taskForm` element. Refer back to the example provided in the description. ```js -assert.match(code, /openTaskFormBtn\.addEventListener\(\s*('|"|`)click\1\s*,\s*\(\s*\)\s*=>\s*(?:{\s*taskForm\s*\.classList\s*\.\s*toggle\s*\(\s*('|"|`)hidden\2\s*\)\s*;?\s*}|\s*taskForm\s*\.classList\s*\.\s*toggle\s*\(\s*('|"|`)hidden\3\s*\)\s*;?\s*)\s*\)\s*;?/) +assert.match(code, /openTaskFormBtn\.addEventListener\(\s*('|"|`)click\1\s*,\s*(?:\(\s*\)\s*=>\s*taskForm\s*\.classList\s*\.\s*toggle\s*\(\s*('|"|`)hidden\2\s*\)\s*\)|\s*function\s*\(\s*\)\s*\s*{\s*taskForm\s*\.classList\s*\.\s*toggle\s*\(\s*('|"|`)hidden\3\s*\)\s*}\s*\)\s*;)/) ``` # --seed--