mirror of
https://github.com/shishantbiswas/bknd.git
synced 2026-03-15 20:17:22 +00:00
Refactor module middleware initialization logic.
Replaced `getMiddleware` with `onServerInit` for streamlined middleware registration. Updated `AppAuth` to automatically register its authentication middleware. Added a test case to verify middleware registration. Removed redundant cookie renewal logic from `AdminController` and made related adjustments across modules.
This commit is contained in:
@@ -243,7 +243,6 @@ export class Authenticator<Strategies extends Record<string, Strategy> = Record<
|
||||
if (this.config.cookie.renew) {
|
||||
const token = await this.getAuthCookie(c);
|
||||
if (token) {
|
||||
console.log("renewing cookie", c.req.url);
|
||||
await this.setAuthCookie(c, token);
|
||||
}
|
||||
}
|
||||
|
||||
Reference in New Issue
Block a user