slightly shorten db.get_token

(no good reason other than i think it looks better)
This commit is contained in:
deneb 2024-02-11 19:04:53 +01:00
parent db133d68d8
commit 5c747f2b41

View file

@ -98,12 +98,9 @@ impl Database for SqliteDatabase {
valid,
created,
last_used,
}| {
if valid {
UserTokenEntry::Valid(UserToken::from(token), created, last_used)
} else {
UserTokenEntry::Invalid(UserToken::from(token), created, last_used)
}
}| match valid {
true => UserTokenEntry::Valid(UserToken::from(token), created, last_used),
false => UserTokenEntry::Invalid(UserToken::from(token), created, last_used),
},
))
}