Fix behavior on Object.create(null).

hasOwn check isnt needed since we use Object.getOwnPropertyNames.