pyxerrors
v1.0.5
Published
e r r o r s
Readme
PyxErrors
It's quite easy
const error = require('pyxerrors')
// some code here that will fail
{/** EXAMPLE */}
var logindata = getlogindata()
// here getlogindata returns nothing
if(!logindata) error.error('Login Error', 'You did not login') //you can also use error.e() or error.err() or by invoking the variable itself 'error()'
Properties
Error.name
The first property is the name, this will change the Errors name accordingly Second is the Description Third is the Status Code, for example 404 or 403
error('Name', 'Description', 400)
//returns Name: Description
at Object.error...
statusCode: 400Status Code Extensions Coming soon!
