inversify/inversify-express-utils

View on GitHub
src/results/NotFoundResult.ts

Summary

Maintainability
A
50 mins
Test Coverage
import { StatusCodes } from 'http-status-codes';
import { HttpResponseMessage } from '../httpResponseMessage';
import type { IHttpActionResult } from '../interfaces';

export class NotFoundResult implements IHttpActionResult {
  public async executeAsync(): Promise<HttpResponseMessage> {
    return Promise.resolve(
      new HttpResponseMessage(StatusCodes.NOT_FOUND)
    );
  }
}