Upgrade to oauth2-pkce 3

Bump oauth2-pkce from ^2.1.3 to ^3.0.0. In v3, getTokens() throws
ErrorAccessTokenExpired when the token has expired and no
onAccessTokenExpiry handler is configured. Add the handler to the
OSM auth client config so it automatically refreshes via the refresh
token instead of throwing
This commit is contained in:
2026-08-06 16:35:11 -05:00
parent 1613ebf0bf
commit 4d4ed8c1ea
3 changed files with 9 additions and 6 deletions
+3
View File
@@ -45,6 +45,9 @@ export default class OsmAuthService extends Service {
clientId: clientId,
redirectUrl: redirectUrl,
storeRefreshToken: true,
onAccessTokenExpiry() {
return this.exchangeRefreshTokenForAccessToken();
},
},
new MarcoOsmAuthStorage()
);
+1 -1
View File
@@ -111,7 +111,7 @@
"ember-concurrency": "^5.2.0",
"ember-lifeline": "^7.1.0",
"nostr-idb": "^5.1.0",
"oauth2-pkce": "^2.1.3",
"oauth2-pkce": "^3.0.0",
"qrcode": "^1.5.4",
"rxjs": "^7.8.2"
}
+5 -5
View File
@@ -41,8 +41,8 @@ importers:
specifier: ^5.1.0
version: 5.1.0
oauth2-pkce:
specifier: ^2.1.3
version: 2.1.3
specifier: ^3.0.0
version: 3.0.0
qrcode:
specifier: ^1.5.4
version: 1.5.4
@@ -4470,8 +4470,8 @@ packages:
nwsapi@2.2.23:
resolution: {integrity: sha512-7wfH4sLbt4M0gCDzGE6vzQBo0bfTKjU7Sfpqy/7gs1qBfYz2vEJH6vXcBKpO3+6Yu1telwd0t9HpyOoLEQQbIQ==}
oauth2-pkce@2.1.3:
resolution: {integrity: sha512-DcMiG5XUKNabf0qV1GOEPo+zwIdYsO2K1FMhiP8XnSCJbujZLOnSC5BCYiCtD0le+aue2fK6qDDvGjcQNF53jQ==}
oauth2-pkce@3.0.0:
resolution: {integrity: sha512-WRqq62rSzWApB4dhttxKJRpgK2GMCeonseH7K567wl9jTI6s9q8dUHrZQpfAlE0NN2FN5WVOF0RvvDtL5+xB6w==}
object-assign@4.1.1:
resolution: {integrity: sha512-rJgTQnkUnH1sFw8yT6VSU3zD3sWmu6sZhIseY8VX+GRu3P6F7Fu+JNDoXfklElbLJSnc3FUQHVe4cU5hj+BcUg==}
@@ -10827,7 +10827,7 @@ snapshots:
nwsapi@2.2.23: {}
oauth2-pkce@2.1.3: {}
oauth2-pkce@3.0.0: {}
object-assign@4.1.1: {}