Skip to content
Advertisement

Trouble using the OR operator in a jQuery if statement

My aim is to check a given ingredient for different attributes with an list of OR statements, but it returns an unexpected || error.

JavaScript

It works when I add and modify the variables individually, does not when I use OR. Any input would be appreciated.

Thanks!

Advertisement

Answer

JavaScript

should be

JavaScript
User contributions licensed under: CC BY-SA
3 People found this is helpful
Advertisement