fix: fixed issue with team-invitations and new user accounts (#3137)
This commit is contained in:
@@ -32,7 +32,7 @@ export class TeamInviteViewerGuard implements CanActivate {
|
|||||||
// Get user
|
// Get user
|
||||||
TE.bindW('user', ({ gqlCtx }) =>
|
TE.bindW('user', ({ gqlCtx }) =>
|
||||||
pipe(
|
pipe(
|
||||||
O.fromNullable(gqlCtx.getContext<{ user?: User }>().user),
|
O.fromNullable(gqlCtx.getContext().req.user),
|
||||||
TE.fromOption(() => BUG_AUTH_NO_USER_CTX),
|
TE.fromOption(() => BUG_AUTH_NO_USER_CTX),
|
||||||
),
|
),
|
||||||
),
|
),
|
||||||
|
|||||||
@@ -33,7 +33,7 @@ export class TeamInviteeGuard implements CanActivate {
|
|||||||
// Get user
|
// Get user
|
||||||
TE.bindW('user', ({ gqlCtx }) =>
|
TE.bindW('user', ({ gqlCtx }) =>
|
||||||
pipe(
|
pipe(
|
||||||
O.fromNullable(gqlCtx.getContext<{ user?: User }>().user),
|
O.fromNullable(gqlCtx.getContext().req.user),
|
||||||
TE.fromOption(() => BUG_AUTH_NO_USER_CTX),
|
TE.fromOption(() => BUG_AUTH_NO_USER_CTX),
|
||||||
),
|
),
|
||||||
),
|
),
|
||||||
|
|||||||
Reference in New Issue
Block a user