Skip to content

Default queryParams for link-to must have values#14068

Merged
rwjblue merged 2 commits intoemberjs:masterfrom
alisdair:fix-link-to-query-params-undefined
Aug 15, 2016
Merged

Default queryParams for link-to must have values#14068
rwjblue merged 2 commits intoemberjs:masterfrom
alisdair:fix-link-to-query-params-undefined

Conversation

@alisdair
Copy link
Contributor

When transitioning between two routes with query params, if the user interrupts the active transition due to a slow model by visiting a third route with no query params, this causes an exception to be raised.

The root cause is that link-to has a default/fallback queryParams of {}, but it needs to have a values field. Otherwise, we pass undefined to the router, which blows up as a result (see #14040).

This PR fixes #14010 at the correct level, and adds a better regression test than #14040.

Thanks to @rwjblue and @GavinJoyce for all their help!

@rwjblue
Copy link
Member

rwjblue commented Aug 15, 2016

screenshot of failing

@rwjblue rwjblue merged commit 07cc789 into emberjs:master Aug 15, 2016
@rwjblue
Copy link
Member

rwjblue commented Aug 15, 2016

Thanks for working so hard at this @alisdair!

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.

Exception thrown from _fullyScopeQueryParams

2 participants