1
0
mirror of https://github.com/stonith404/pingvin-share.git synced 2024-11-04 23:10:13 +01:00

Revert "fix: jwt guard when unauthenticated shares are allowed"

This reverts commit c2b87aba5c.
This commit is contained in:
Elias Schneider 2022-10-24 09:25:45 +02:00
parent 712cfe625a
commit ffdecbd32e

View File

@ -9,9 +9,8 @@ export class JwtGuard extends AuthGuard("jwt") {
canActivate(
context: ExecutionContext
): boolean | Promise<boolean> | Observable<boolean> {
return (
super.canActivate(context) ||
process.env.ALLOW_UNAUTHENTICATED_SHARES == "true"
);
return process.env.ALLOW_UNAUTHENTICATED_SHARES == "true"
? true
: super.canActivate(context);
}
}