Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Resolve redirect #592

Closed
wants to merge 6 commits into from
Closed

Conversation

fkleuver
Copy link
Member

Should fix #480

Use Promise.resolve instead of Promise.reject when handling a redirect.

BuildNavigationPlanStep.run will check if the returned value from .then() is a Redirect, and if so, and call next.cancel.

The tests still pass but it kind of feels like I'm missing something. It seems "too easy". Maybe LoadRouteStep.run also needs to be changed (loop through the values and if any of them is a Redirect, call next.cancel).

@davismj Do you know if it's possible for a redirect to end up in LoadRouteStep but not in BuildNavigationPlanStep?

@davismj
Copy link
Member

davismj commented Apr 30, 2018

Thanks for the hard work Fred. I've never heard of a redirect occurring in the load route step.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

Configuring a route with "redirect" property causes BlueBird warnings
2 participants