This kind of hard coding isn't very library friendly. Why the special casing of `1`? Also, `==` should be `===` unless coercion is needed.