1
0
mirror of https://github.com/matrix-org/matrix-authentication-service.git synced 2025-07-29 22:01:14 +03:00

storage: make the access token expiration optional

This commit is contained in:
Quentin Gliech
2023-09-11 11:37:06 +02:00
parent e6b91c1ce4
commit 9c97a0c37a
11 changed files with 36 additions and 41 deletions

View File

@ -177,10 +177,9 @@ impl OAuth2SessionMutations {
}
let ttl = if permanent {
// XXX: that's lazy
Duration::days(365 * 50)
None
} else {
Duration::minutes(5)
Some(Duration::minutes(5))
};
let access_token = repo
.oauth2_access_token()