feat: generalize defaut user middleware

This commit is contained in:
2024-05-02 09:42:56 +02:00
parent 6aec6da078
commit 0f673671b8
4 changed files with 149 additions and 106 deletions

View File

@ -252,7 +252,7 @@ func runApp(ctx context.Context, path, address, documentStoreDSN, blobStoreDSN,
fetchModule.Mount(),
),
appHTTP.WithHTTPMiddlewares(
authModuleMiddleware.AnonymousUser(key, jwa.HS256),
authModuleMiddleware.DefaultUser(key, jwa.HS256, authModuleMiddleware.WithAnonymousUser()),
),
)
if err := handler.Load(ctx, bundle); err != nil {