Back to Pocketbase

Function requireSuperuserOrOwnerAuth

static/jsvm/functions/_apis.requireSuperuserOrOwnerAuth.html

latest1004 B
Original Source

Function requireSuperuserOrOwnerAuth

RequireSuperuserOrOwnerAuth middleware requires a request to have a valid superuser or regular record owner Authorization header set.

This middleware is similar to [apis.RequireAuth()] but for the auth record token expects to have the same id as the path parameter ownerIdPathParam (default to "id" if empty).

Parameters

ownerIdPathParam: string

Returns hook.Handler<RequestEvent>

Settings

Member Visibility

  • Inherited

Theme

OSLightDark

Generated using TypeDoc