aboutsummaryrefslogtreecommitdiffstats
path: root/src/ng/location.js
diff options
context:
space:
mode:
authorIgor Minar2014-01-09 23:16:06 -0800
committerIgor Minar2014-01-09 23:47:35 -0800
commit5a4145fe16bb61720843ae938b789e32dbbfdb7d (patch)
tree735c964f23bf1d56a5c7dfd96a661ba31ab3ad5b /src/ng/location.js
parent039b990d8dc73e59418114b49c36797e44127c76 (diff)
downloadangular.js-5a4145fe16bb61720843ae938b789e32dbbfdb7d.tar.bz2
revert: fix($location): return '/' for root path in hashbang mode
This reverts commit 63cd873fef3207deef30c7a7ed66f4b8f647dc12. The change breaks existing tests of Google apps. The problem is that while we tried to avoid adding #/ to window.location.href unnecessarily we failed doing so. Likely because by setting $path, at some point (during a digest) we try to check if $location changed and we mistake the default '/' with an explicit settign of the path via the `path()` method. This results in us writing the url with '#/' into $browser.url() which updates the window.location by adding "#/" to the url - something we tried to avoid in the first place. I'll reopen PR #5712.
Diffstat (limited to 'src/ng/location.js')
-rw-r--r--src/ng/location.js4
1 files changed, 0 insertions, 4 deletions
diff --git a/src/ng/location.js b/src/ng/location.js
index d193b1ca..0a47445f 100644
--- a/src/ng/location.js
+++ b/src/ng/location.js
@@ -184,10 +184,6 @@ function LocationHashbangUrl(appBase, hashPrefix) {
this.$$compose();
- if (!this.$$path) {
- this.$$path = '/';
- }
-
/*
* In Windows, on an anchor node on documents loaded from
* the filesystem, the browser will return a pathname