We read every piece of feedback, and take your input very seriously.
To see all available qualifiers, see our documentation.
There was an error while loading. Please reload this page.
1 parent b25ddb2 commit 7b24ceaCopy full SHA for 7b24cea
hooks/tryAuthenticate.ts
@@ -3,6 +3,9 @@ import { authenticate } from '@feathersjs/authentication';
3
4
5
export default async (context: HookContext): Promise<HookContext> => {
6
- return authenticate('jwt')(context).catch(() => context);
+ if (context.params?.headers?.authorization && context.path !== 'authentication') {
7
+ return authenticate('jwt')(context);
8
+ }
9
+ return context;
10
};
11
0 commit comments