Don't use "in" operator where a typeof foo check can be used.

cc @cscott

All tests passing

Signed-off-by: Rick Waldron <waldron.rick@gmail.com>