import HttpStatusCode from "./http-status";

class HttpError extends Error {
  /**
   * HTTP Status Code
   */
  status: HttpStatusCode;
  message: string;

  constructor(status: HttpStatusCode, message: string) {
    super(message);

    this.name = "HttpError";
    this.status = status;
    this.message = message;
  }
}

export default HttpError;
