Commit 7d5da0ee authored by brandonaaron's avatar brandonaaron

Make sure events exist before trying to access them in jQuery.event.handle and...

Make sure events exist before trying to access them in jQuery.event.handle and removed unnecessary var statement. Fixes #6163.
parent 9e06903a
...@@ -374,7 +374,8 @@ jQuery.event = { ...@@ -374,7 +374,8 @@ jQuery.event = {
namespace = new RegExp("(^|\\.)" + namespaces.slice(0).sort().join("\\.(?:.*\\.)?") + "(\\.|$)"); namespace = new RegExp("(^|\\.)" + namespaces.slice(0).sort().join("\\.(?:.*\\.)?") + "(\\.|$)");
} }
var events = jQuery.data(this, "events"), handlers = events[ event.type ]; events = jQuery.data(this, "events");
handlers = (events || {})[ event.type ];
if ( events && handlers ) { if ( events && handlers ) {
// Clone the handlers to prevent manipulation // Clone the handlers to prevent manipulation
......
Markdown is supported
0% or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment