From 021231507270332279187a12482f2f1c3b5dda17 Mon Sep 17 00:00:00 2001 From: Gabriel Schulhof Date: Wed, 5 Sep 2012 00:11:28 +0300 Subject: [PATCH] [navigation] Do not reset the base tag if, during loadPage we find that the page is already in the DOM, or that we have been prevented from continuing because the default for the "pagebeforeload" event has been prevented. --- js/jquery.mobile.navigation.js | 10 +++++----- 1 file changed, 5 insertions(+), 5 deletions(-) diff --git a/js/jquery.mobile.navigation.js b/js/jquery.mobile.navigation.js index 25ed8b8b231..884c347c1bf 100644 --- a/js/jquery.mobile.navigation.js +++ b/js/jquery.mobile.navigation.js @@ -724,11 +724,6 @@ define( [ } } - // Reset base to the default document base. - if ( base ) { - base.reset(); - } - // If the page we are interested in is already in the DOM, // and the caller did not indicate that we should force a // reload of the file, we are done. Otherwise, track the @@ -772,6 +767,11 @@ define( [ }; } + // Reset base to the default document base. + if ( base ) { + base.reset(); + } + if ( !( $.mobile.allowCrossDomainPages || path.isSameDomain( documentUrl, absUrl ) ) ) { deferred.reject( absUrl, options ); } else {