Problem with "Regular Expressions: Match Single Character with Multiple Possibilities"

I am having trouble with matching the vowels with regex. As far as I can tell, my code should work. Either there is a bug in this challenge or I am missing something simple. Below is my code:

Use a character class with vowels (a, e, i, o, u) in your regex vowelRegex to find all the vowels in the string quoteSample.

Note
Be sure to match both upper- and lowercase vowels.

1 let quoteSample = “Beware of bugs in the above code; I have only proved it correct, not tried it.”;
2 let vowelRegex = /[aeiou]/gi; // Change this line
3 let result = vowelRegex.match(quoteSample); // Change this line

Is anyone else having the same trouble?

1 Like

You are not implementing the match method properly. Review the examples again. Where should the string go vs the regular expression?

2 Likes

Yup I thought it might be something simple I was not seeing.

Thanks for your help!