File tree Expand file tree Collapse file tree 2 files changed +3
-1
lines changed Expand file tree Collapse file tree 2 files changed +3
-1
lines changed Original file line number Diff line number Diff line change @@ -447,10 +447,10 @@ function onPjaxPopstate(event) {
447447 if ( contents ) {
448448 container . trigger ( 'pjax:start' , [ null , options ] )
449449
450+ pjax . state = state
450451 if ( state . title ) document . title = state . title
451452 container . trigger ( 'pjax:beforeReplace' , [ contents , options ] )
452453 container . html ( contents )
453- pjax . state = state
454454
455455 container . trigger ( 'pjax:end' , [ null , options ] )
456456 } else {
Original file line number Diff line number Diff line change @@ -547,6 +547,7 @@ if ($.support.pjax) {
547547 ok ( contents )
548548 equal ( $ ( event . target ) . text ( ) , beforeContent )
549549 equal ( options . url , "hello.html" )
550+ ok ( frame . $ . pjax . state . url . match ( "/hello.html" ) )
550551 } )
551552 frame . $ ( "#main" ) . on ( "pjax:success" , function ( event ) {
552553 notEqual ( $ ( event . target ) . text ( ) , beforeContent )
@@ -866,6 +867,7 @@ if ($.support.pjax) {
866867 equal ( frame . location . pathname , "/home.html" )
867868 // Remember: the content hasn't yet been replaced.
868869 notEqual ( $ ( event . target ) . html ( ) , originalContent )
870+ ok ( frame . $ . pjax . state . url . match ( "/home.html" ) )
869871 start ( )
870872 } )
871873
You can’t perform that action at this time.
0 commit comments