Reputation: 100322
If I extend the Object
prototype and try to use some functions of jQuery 2.0.3 I get errors...
Object.prototype.GetHashCode = function() { return 1; };
$(document).on("click", "div", function() { });
If I do this and then click any div I get an error
Uncaught TypeError: Object function () { return 1; } has no method 'exec'
Why does it happen? Is there a workaround or a way to fix this bug in jQuery?
Upvotes: 4
Views: 854