iamolegga/nestjs-roles

View on GitHub

Showing 1 of 2 total issues

Function checkRoles has 29 lines of code (exceeds 25 allowed). Consider refactoring.
Open

export function checkRoles<R>(
  requiredRoles: [R, ...R[]] | [boolean],
  role: R | R[] | undefined,
) {
  // handler is allowed only for not authorized
Severity: Minor
Found in src/check-roles.ts - About 1 hr to fix
    Severity
    Category
    Status
    Source
    Language