thekevinscott / UpscalerJS

Found redundant literal in a logical expression JS-W1043
Anti-pattern
Minor
6 months ago8 months old
Logical expression with a literal operand will always evaluate to the same value
105  }
106
107  const headers = getHeaders(cacheLength)
108  const origin = request.headers.get('origin') || '';109  try {
110    if (!ALLOWED_DOMAINS.includes(origin)) {
111      console.log(`Should 403, because origin is not in allowed domains. Origin is "${origin}" and ALLOWED_DOMAINS include`, ALLOWED_DOMAINS)