isNaN(null) returns false and isNaN('1') (for example) also returns false so that condition isn't valid either