Skip to content

Commit

Permalink
Fix event.initEvent for Firefox
Browse files Browse the repository at this point in the history
This function requires three arguments: type, bubbles, and cancelable.
We failed to give the second and third arguments, which caused the spec
to throw errors in Firefox.
  • Loading branch information
lencioni committed Jan 28, 2015
1 parent 5b30f27 commit 8df96af
Showing 1 changed file with 1 addition and 1 deletion.
2 changes: 1 addition & 1 deletion spec/waypoint_spec.js
Original file line number Diff line number Diff line change
Expand Up @@ -11,7 +11,7 @@ var renderAttached = function(component) {
var scrollNodeTo = function(node, scrollTop) {
node.scrollTop = scrollTop;
var event = document.createEvent('Event');
event.initEvent('scroll');
event.initEvent('scroll', false, false);
node.dispatchEvent(event);
};

Expand Down

0 comments on commit 8df96af

Please sign in to comment.