File

lib/shared/exceptions/too-many-requests-ms.exception.ts

Description

Custom microservice exception for too many requests, extending MsException.

Extends

MsException

Constructor

constructor(message?: string)
Parameters :
Name Type Optional
message string Yes
import { HttpStatus } from "@nestjs/common";
import { MsException } from "./ms.exception";

/**
 * Custom microservice exception for too many requests, extending MsException.
 */
export class TooManyRequestsMsException extends MsException {
  constructor(message?: string) {
    super(
      HttpStatus.TOO_MANY_REQUESTS,
      message || "You have made too many requests. Please try again later.",
    );
  }
}

results matching ""

    No results matching ""