Fix potential ReferenceError in non-browser env

Testing for `window` would throw if undeclared.
Also, avoid repeating feature check.

Also, as it stands `type` as used in `logIt` would always be `0`. Perhaps `logIt` should be curried when patched to `console.x`?