UNPKG

@gam-test/fetch-wrapper

Version:

A simple fetch wrapper for better error handling and less response context

20 lines 841 B
import { BadRequestException } from "./BadRequestException.js"; import { ConflictException } from "./ConflictException.js"; import { ForbiddenException } from "./ForbiddenException.js"; import { InternalServerErrorException } from "./InternalServerErrorException.js"; import { NotFoundException } from "./NotFoundException.js"; import { PayloadTooLargeException } from "./PayloadTooLargeException.js"; import { UnauthorizedException } from "./UnauthorizedException.js"; const statusCodeExceptionsMap = /* @__PURE__ */ new Map([ [400, BadRequestException], [401, UnauthorizedException], [403, ForbiddenException], [404, NotFoundException], [409, ConflictException], [413, PayloadTooLargeException], [500, InternalServerErrorException] ]); export { statusCodeExceptionsMap }; //# sourceMappingURL=statusCodeExceptionsMap.js.map