fix a minor bug in navigation-controller where a string is used as an object

This commit is contained in:
liusy182 2016-09-08 21:31:42 +08:00
parent 0b7b6b38c0
commit 180a77e671

View file

@ -49,9 +49,10 @@ var NavigationController = (function () {
// Normal navigation. Clear history. // Normal navigation. Clear history.
this.history = this.history.slice(0, this.currentIndex + 1) this.history = this.history.slice(0, this.currentIndex + 1)
currentEntry = this.history[this.currentIndex] currentEntry = this.history[this.currentIndex]
if ((currentEntry != null ? currentEntry.url : void 0) !== url) {
if ((currentEntry != null ? currentEntry : void 0) !== url) {
this.currentIndex++ this.currentIndex++
return this.history.push(url) this.history.push(url)
} }
} }
}) })