tangled
alpha
login
or
join now
flo-bit.dev
/
blento
21
fork
atom
your personal website on atproto - mirror
blento.app
21
fork
atom
overview
issues
pulls
pipelines
fix logout on refresh
Florian
2 weeks ago
680d33ce
d15e10ba
+3
-1
1 changed file
expand all
collapse all
unified
split
src
lib
atproto
auth.svelte.ts
+3
-1
src/lib/atproto/auth.svelte.ts
···
206
206
throw Error('session expired');
207
207
}
208
208
209
209
-
if (session.token.scope !== metadata.scope) {
209
209
+
const requestedScopes = metadata.scope.split(' ').filter((s) => !s.startsWith('include:'));
210
210
+
const tokenScopes = new Set(session.token.scope?.split(' '));
211
211
+
if (!requestedScopes.every((s) => tokenScopes.has(s))) {
210
212
throw Error('scope changed, signing out!');
211
213
}
212
214