Skip to content

BUG - handlers with AllowAnonymous decorator still use better-auth getSession and hit DB connection #159

Description

@JSteunou

Use case: I have liveness / readyness endpoints and those check the DB connection among other things. Those endpoints are anonymous.

Issue : error for DB connection failure rise before I can do my check with my logic with my error handling, error code, msg because AuthGuard.canActivate calls getSession() before checking on AllowAnonymous . isPublic is never reached.

Metadata

Metadata

Assignees

No one assigned

    Labels

    No labels
    No labels

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions