why am I getting the error which says unable to get the property webPermMasks of undefined or null references?
help me solve this error.
Make sure the syntax in your conditions are correct. There is a chance it might be missing brackets or comma or something.
If not then please make sure that the script you're using doesn't have any error.