How to use the @feathersjs/commons._ function in @feathersjs/commons

To help you get started, we’ve selected a few @feathersjs/commons examples, based on popular ways it is used in public projects.

Secure your code as it's written. Use Snyk Code to scan source code in minutes - no build needed - and fix issues immediately.

github feathersjs / feathers / packages / express / lib / rest / getHandler.js View on Github external
const errors = require('@feathersjs/errors');
const { omit } = require('@feathersjs/commons')._;
const debug = require('debug')('@feathersjs/express/rest');

const statusCodes = {
  created: 201,
  noContent: 204,
  methodNotAllowed: 405
};
const methodMap = {
  find: 'GET',
  get: 'GET',
  create: 'POST',
  update: 'PUT',
  patch: 'PATCH',
  remove: 'DELETE'
};