Browse Source

chore: lint

pull/7569/head
Pranav C 11 months ago
parent
commit
c3f1a58d68
  1. 3
      packages/nocodb/src/helpers/apiHelpers.ts
  2. 2
      packages/nocodb/src/strategies/jwt.strategy.ts

3
packages/nocodb/src/helpers/apiHelpers.ts

@ -45,7 +45,8 @@ export const validatePayload = (schema: string, payload: any) => {
// If the request body is not valid, throw error
if (!valid) {
const errors: ErrorObject[] | null | undefined = ajv.errors || validate.errors;
const errors: ErrorObject[] | null | undefined =
ajv.errors || validate.errors;
// If the request body is invalid, throw error with error message and errors
NcError.ajvValidationError({

2
packages/nocodb/src/strategies/jwt.strategy.ts

@ -15,7 +15,7 @@ export class JwtStrategy extends PassportStrategy(Strategy) {
async validate(req, jwtPayload) {
if (!jwtPayload?.email) {
return jwtPayload
return jwtPayload;
}
const user = await User.getByEmail(jwtPayload?.email);

Loading…
Cancel
Save