aws/src/lib/slack/verify.ts
Showing 4 of 4 total issues
Function verify
has 36 lines of code (exceeds 25 allowed). Consider refactoring. Open
Open
export const verify = async (req: APIGatewayProxyEventV2): Promise<boolean> => { const version = 'v0'; const headers = CaseInsensitiveMap.fromObject(req.headers); const actual = headers.get('X-Slack-Signature');
Function verify
has a Cognitive Complexity of 7 (exceeds 5 allowed). Consider refactoring. Open
Open
export const verify = async (req: APIGatewayProxyEventV2): Promise<boolean> => { const version = 'v0'; const headers = CaseInsensitiveMap.fromObject(req.headers); const actual = headers.get('X-Slack-Signature');
- Read upRead up
Avoid too many return
statements within this function. Open
Open
return false;
Avoid too many return
statements within this function. Open
Open
return ok;