Use `obj == null` instead to allow getting properties on primitives, such as toString.
Add tests for getting property when encountering primitive/non-primitive.