Fixed a bug of HashIterator

The old implementation of HashIterator can't support `"\0"` prefix key.
I think the array and the object is different. Maybe the user didn't
want to get the private property of an object. but in an array, `"\0"`
prefix key doesn't mean private key. so we should return `"\0"` prefix
key when it is an array.