commit | a4a47112ac827905fff860b4d68afa1baea3c83a | [log] [tgz] |
---|---|---|
author | Matteo Scandolo <matteo.scandolo@gmail.com> | Fri Dec 16 10:06:13 2016 -0800 |
committer | Matteo Scandolo <matteo.scandolo@gmail.com> | Fri Dec 16 14:38:46 2016 -0800 |
tree | 5e68e7350035ed80c891d6069c591b6a1997608a | |
parent | 52fa5cbc7d9d18bc05b1ba395b792bccbe455500 [diff] [blame] |
Added tests Change-Id: I493675212f4b1548b32a6d92ce3664d184bc0e04
diff --git a/src/app/core/services/navigation.ts b/src/app/core/services/navigation.ts index 8cb3b66..04eb575 100644 --- a/src/app/core/services/navigation.ts +++ b/src/app/core/services/navigation.ts
@@ -26,6 +26,9 @@ } add(route: IXosNavigationRoute) { + if (angular.isDefined(route.state) && angular.isDefined(route.url)) { + throw new Error('[XosNavigation] You can\'t provide both state and url'); + } this.routes.push(route); } }