How to use the RestError function from restify
Find comprehensive JavaScript restify.RestError code examples handpicked from public code repositorys.
99 100 101 102 103 104 105 106 107 108
// ---- globals var p = console.warn; var fmt = util.format; var RestError = restify.RestError; // ---- exported functions
49
182
65
+ 3 other calls in file
303 304 305 306 307 308 309 310 311 312
var restify = require('restify'); var util = require('util'); function MyError(message) { restify.RestError.call(this, { restCode: 'MyError' statusCode: 418, message: message, constructorOpt: MyError
18
42
7
+ 15 other calls in file
18 19 20 21 22 23 24 25 26 27 28 29 30
*/ var util = require('util'), format = util.format; var restify = require('restify'), RestError = restify.RestError; var assert = require('assert-plus'); //---- globals
17
5
0
restify.createServer is the most popular function in restify (1059 examples)