Abort previous pending XHR when navigating #114

Merged
robinnorth merged 4 commits from fix/abort-pending-xhr into master 2018-01-24 18:54:34 -05:00
Showing only changes of commit ff62289683 - Show all commits

View File

@@ -5,6 +5,8 @@ var forEachEls = require("./lib/foreach-els.js")
var newUid = require("./lib/uniqueid.js")
var noop = require("./lib/util/noop")
BehindTheMath commented 2018-01-24 18:25:25 -05:00 (Migrated from github.com)
Review

Can you change this as well to noop.js?

Can you change this as well to `noop.js`?
var on = require("./lib/events/on.js")
// var off = require("./lib/events/on.js")
var trigger = require("./lib/events/trigger.js")
@@ -331,10 +333,10 @@ if (Pjax.isSupported()) {
}
// if there isnt required browser functions, returning stupid api
else {
var stupidPjax = function() {}
var stupidPjax = noop
for (var key in Pjax.prototype) {
if (Pjax.prototype.hasOwnProperty(key) && typeof Pjax.prototype[key] === "function") {
stupidPjax[key] = stupidPjax
stupidPjax[key] = noop
}
}