Skip to content

Commit 4245adf

Browse files
committed
fix: remove redundant token validation check per review feedback
1 parent c01e017 commit 4245adf

File tree

1 file changed

+0
-4
lines changed

1 file changed

+0
-4
lines changed

packages/crypto/src/tokenUtils.ts

Lines changed: 0 additions & 4 deletions
Original file line numberDiff line numberDiff line change
@@ -3,10 +3,6 @@ import { Token } from "@sourcebot/schemas/v3/shared.type";
33
import { decrypt } from "./index.js";
44

55
export const getTokenFromConfig = async (token: Token, orgId: number, db: PrismaClient) => {
6-
if (typeof token !== 'object' || token === null) {
7-
throw new Error('Invalid token configuration');
8-
}
9-
106
if ('secret' in token) {
117
const secretKey = token.secret;
128
const secret = await db.secret.findUnique({

0 commit comments

Comments
 (0)