JavaScript: Check list of arguments if null or undefined