mirror of
https://github.com/freeCodeCamp/freeCodeCamp.git
synced 2026-01-05 21:03:24 -05:00
fix(curriculum): update test regex to allow whitespaces (#47150)
* Added spacing fix to catch end of line spaces
* allow for spaces before "("
This commit is contained in:
@@ -33,7 +33,7 @@ Your promise should receive a function with `resolve` and `reject` as parameters
|
||||
```js
|
||||
assert(
|
||||
code.match(
|
||||
/Promise\(\s*(function\s*\(\s*resolve\s*,\s*reject\s*\)\s*{|\(\s*resolve\s*,\s*reject\s*\)\s*=>\s*{)[^}]*}/g
|
||||
/Promise\s*\(\s*(function\s*\(\s*resolve\s*,\s*reject\s*\)\s*{|\(\s*resolve\s*,\s*reject\s*\)\s*=>\s*{)[^}]*}/g
|
||||
)
|
||||
);
|
||||
```
|
||||
|
||||
Reference in New Issue
Block a user