aboutsummaryrefslogtreecommitdiffstats
diff options
context:
space:
mode:
-rw-r--r--docs/content/error/location/istart.ngdoc4
-rw-r--r--src/ng/location.js3
-rw-r--r--test/ng/locationSpec.js7
3 files changed, 0 insertions, 14 deletions
diff --git a/docs/content/error/location/istart.ngdoc b/docs/content/error/location/istart.ngdoc
deleted file mode 100644
index 006689e4..00000000
--- a/docs/content/error/location/istart.ngdoc
+++ /dev/null
@@ -1,4 +0,0 @@
-@ngdoc error
-@name $location:istart
-@fullName Invalid URL
-@description
diff --git a/src/ng/location.js b/src/ng/location.js
index 7b0c6ec0..f4f77c2f 100644
--- a/src/ng/location.js
+++ b/src/ng/location.js
@@ -161,9 +161,6 @@ function LocationHashbangUrl(appBase, hashPrefix) {
*/
this.$$parse = function(url) {
var withoutBaseUrl = beginsWith(appBase, url) || beginsWith(appBaseNoFile, url);
- if (!isString(withoutBaseUrl)) {
- throw $locationMinErr('istart', 'Invalid url "{0}", does not start with "{1}".', url, appBase);
- }
var withoutHashUrl = withoutBaseUrl.charAt(0) == '#'
? beginsWith(hashPrefix, withoutBaseUrl)
: (this.$$html5)
diff --git a/test/ng/locationSpec.js b/test/ng/locationSpec.js
index 757ec16e..4df6eb43 100644
--- a/test/ng/locationSpec.js
+++ b/test/ng/locationSpec.js
@@ -338,13 +338,6 @@ describe('$location', function() {
});
- it('should throw error when invalid server url given', function() {
- expect(function() {
- url.$$parse('http://server.org/path#/path');
- }).toThrow('[$location:istart] Invalid url "http://server.org/path#/path", does not start with "http://www.server.org:1234/base".');
- });
-
-
it('should throw error when invalid hashbang prefix given', function() {
expect(function() {
url.$$parse('http://www.server.org:1234/base#/path');