Improve performance of Object.hasProperty