Safer access to hasOwnProperty

This makes access to hasOwnProperty safer. Otherwise the module fails to clone an object that looks like this and throws an exception:
var myObj = {"hasOwnProperty": "test"};