{"version":3,"sources":["../src/typeguards/isHttpException.ts"],"names":["isHttpException","error","checkStatusCode","HttpException"],"mappings":"qCAOO,IAAMA,CAAAA,CAAkB,CAC7BC,CAAAA,CAGAC,CAAAA,CAAkB,IAAA,GAGhBD,CAAAA,YAAiBE,CAAAA,GAChB,CAACD,CAAAA,EAAoBD,CAAAA,CAAM,UAAA,CAAa,GAAA,EAAOA,EAAM,UAAA,CAAa,GAAA","file":"chunk-FR66RLI7.mjs","sourcesContent":["import { HttpException } from '../base/HttpException';\n\n/**\n * Test whether a value is an instanceof HttpException\n * and its statusCode is in the 4xx and 5xx ranges when the parameter\n * checkStatusCode is true (enabled by default).\n */\nexport const isHttpException = (\n  error: unknown /**\n   * Ensure statusCode is in the error range [>=400, <600], true by default\n   */,\n  checkStatusCode = true\n): error is HttpException => {\n  return (\n    error instanceof HttpException &&\n    (!checkStatusCode || (error.statusCode > 399 && error.statusCode < 600))\n  );\n};\n"]}