Skip to content

Commit 8dee17e

Browse files
committed
Merge pull request CodeByZach#6 from kaleworsley/master
Change window.pushState to window.history.pushState.
2 parents f47d6dd + bbd1309 commit 8dee17e

File tree

3 files changed

+17
-17
lines changed

3 files changed

+17
-17
lines changed

pace.coffee

Lines changed: 8 additions & 8 deletions
Original file line numberDiff line numberDiff line change
@@ -391,19 +391,19 @@ handlePushState = ->
391391
Pace.restart()
392392

393393
# We reset the bar whenever it looks like an ajax navigation has occured.
394-
if window.pushState?
395-
_pushState = window.pushState
396-
window.pushState = ->
394+
if window.history.pushState?
395+
_pushState = window.history.pushState
396+
window.history.pushState = ->
397397
handlePushState()
398398

399-
_pushState arguments...
399+
_pushState.apply window.history, arguments
400400

401-
if window.replaceState?
402-
_replaceState = window.replaceState
403-
window.replaceState = ->
401+
if window.history.replaceState?
402+
_replaceState = window.history.replaceState
403+
window.history.replaceState = ->
404404
handlePushState()
405405

406-
_replaceState arguments...
406+
_replaceState.apply window.history, arguments
407407

408408
SOURCE_KEYS =
409409
ajax: AjaxMonitor

pace.js

Lines changed: 8 additions & 8 deletions
Some generated files are not rendered by default. Learn more about customizing how changed files appear on GitHub.

pace.min.js

Lines changed: 1 addition & 1 deletion
Some generated files are not rendered by default. Learn more about customizing how changed files appear on GitHub.

0 commit comments

Comments
 (0)