Fixed issue where couldn't set history state to 'false'

This commit is contained in:
Anthony Hughes
2016-10-01 19:23:57 +02:00
parent acdd87ef3d
commit f7cce3c04d

View File

@@ -6,7 +6,7 @@ module.exports = function(options){
this.options.selectors = this.options.selectors || ["title", ".js-Pjax"]
this.options.switches = this.options.switches || {}
this.options.switchesOptions = this.options.switchesOptions || {}
this.options.history = this.options.history || true
this.options.history = (typeof this.options.history === 'undefined') ? true : this.options.history
this.options.analytics = this.options.analytics || function() {
// options.backward or options.foward can be true or undefined
// by default, we do track back/foward hit