Closed adamreisnz closed 4 years ago
Simply returning target
seems to work now.
This issue has been automatically marked as stale because it has not had recent activity. It will be closed if no further activity occurs.
This does not mean that the issue is invalid. Valid issues may be reopened.
Thank you for your contributions.
This issue tracker is for Bug Reports and Feature Requests only.
This is a (check one box):
My version of UI-Router is: 1.0.20 (core 5.0.21)
Bug Report
Current Behavior:
ERROR TypeError: stateName.indexOf is not a function at StateMatcher.isRelative (ui-router-core.js:1751) at StateMatcher.find (ui-router-core.js:1759) at new TargetState (ui-router-core.js:1162) at StateService.target (ui-router-core.js:3980) at auth.js:45 at processQueue (angular.js:9493) at angular.js:9539 at Scope.$digest (angular.js:10096) at Scope.$apply (angular.js:10238) at done (angular.js:6404)
This is triggered from the following (simplified) code:
Expected Behavior:
To be redirected to the target state. This used to work fine several versions back. As per the docs: https://ui-router.github.io/ng1/docs/latest/classes/state.stateservice.html#target
Link to Plunker or stackblitz that reproduces the issue:
https://stackblitz.com/edit/ui-router-angularjs-pcj7tg