Error message on Rock/paper/scissor exercise

Hi all, I was wondering where the error in my code is? Feel like i’ve made a really simply mistake but can’t tell where the issue is

Any help would be appreciated :slight_smile:

When you call the getUserChoice function, what argument do you provide? If you don’t provide any, you get undefined

toLowerCase() is a string method, and doesn’t work on undefined

(IMHO javascript should throw an error that you didn’t provide an argument/value for a required parameter)

1 Like

Hi, thanks for the help! I’ve been able to resolve the issue :slight_smile: