Since hasOwnProperty has some caveats and quirks (window / extensive use in Internet Explorer 8 issues, etc.):
Is there any reason to even use it
hasOwnProperty does not check for undefined values. It only checks if a property is assigned to the object even if is undefined:
var obj = { a : undefined }; obj.hasOwnProperty("a") // true obj.a === undefined // true obj.hasOwnProperty("b") // false obj.b === undefined // true