add metatable to make sure hash and array