Spam Filter JS Project

i am facing a error in spam filter / step 19 , this code is not working properly
const dollarRegex = /[0-9]+ (hundred|thousand|million|billion)? dollars/i;
problem : this regex match with (2\s\sdollars) but not with ( 2\sdollars);

here is the link

this is a code

hi and welcome to the forum.

This code passes the step. Can you clarify what you need help with?