This commit is contained in:
boufni95 2025-07-08 20:00:43 +00:00
parent 2cc02b35c5
commit 6abed0e448

View file

@ -242,10 +242,12 @@ export class ManagementManager {
const grant = await this.storage.managementStorage.getGrant(appUserId, requestorPub)
if (!grant) {
this.logger(ERROR, "No grant found", appUserId, requestorPub)
return { state: 'authRequired' }
}
if (grant.expires_at_unix > 0 && grant.expires_at_unix < Date.now()) {
this.logger(ERROR, "Grant expired", appUserId, requestorPub)
return { state: 'authRequired' }
}