Skip to content

Commit da4ede8

Browse files
committed
Auto merge of #2029 - Turbo87:qp, r=carols10cents
routes/github-authorize: Fix `queryParams` code Accessing `queryParams` on the `transition` object was never officially public API in Ember.js, and has been deprecated in Ember.js v3.6 (see https://deprecations.emberjs.com/v3.x#toc_transition-state). Since it was only considered "intimate" API its removal was done in v3.9 instead of v4.0. Since we skipped both of these versions we unfortunately never saw the corresponding deprecation warning... 😞 But even if we did upgrade to v3.8 LTS in between, we probably still would have missed it, because the `github-authorize` route is only called in a popup window where the usual DevTools console is not attached, and we unfortunately don't have any test for the login flow (yet!). Closes #2027, Resolves #2028 @carols10cents r?
2 parents 084f76e + 1989917 commit da4ede8

File tree

1 file changed

+1
-1
lines changed

1 file changed

+1
-1
lines changed

app/routes/github-authorize.js

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -18,7 +18,7 @@ import { serializeQueryParams } from 'ember-fetch/utils/serialize-query-params';
1818
export default Route.extend({
1919
async beforeModel(transition) {
2020
try {
21-
let queryParams = serializeQueryParams(transition.queryParams);
21+
let queryParams = serializeQueryParams(transition.to.queryParams);
2222
let resp = await fetch(`/api/private/session/authorize?${queryParams}`);
2323
let json = await resp.json();
2424
let item = JSON.stringify({ ok: resp.ok, data: json });

0 commit comments

Comments
 (0)