javascript test if variable is boolean