simple-http-errors

0.0.1 • Public • Published

Simple HTTP Errors

A simple error maker thingy.

Codes

UNAUTHORIZED: 401
NOT_FOUND: 404
UNPROCESSABLE_ENTITY: 422

(more coming as needed)

Use

var errors = require('simple-http-errors');

//...
if (item === undefined) {
  return next(errors.notFound());
}

Readme

Keywords

Package Sidebar

Install

npm i simple-http-errors

Weekly Downloads

0

Version

0.0.1

License

MIT

Last publish

Collaborators

  • nathanhoad