Skip to content

Commit

Permalink
Fix wrong this usage in nanohref integration (#689)
Browse files Browse the repository at this point in the history
I currently see `TypeError: undefined is not an object (evaluating 'this._hashEnabled')` being thrown by clients. This should fix it.
  • Loading branch information
mantoni authored and goto-bus-stop committed Oct 30, 2018
1 parent f5f8ccf commit c9356a6
Showing 1 changed file with 1 addition and 1 deletion.
2 changes: 1 addition & 1 deletion index.js
Original file line number Diff line number Diff line change
Expand Up @@ -129,7 +129,7 @@ Choo.prototype.start = function () {
var href = location.href
var hash = location.hash
if (href === window.location.href) {
if (!this._hashEnabled && hash) scrollToAnchor(hash)
if (!self._hashEnabled && hash) scrollToAnchor(hash)
return
}
self.emitter.emit(self._events.PUSHSTATE, href)
Expand Down

0 comments on commit c9356a6

Please sign in to comment.