lib/errors.js
function debug( err, req, res, next ) {
        res.status( err.status || 500 );

        err.guid = uuid.v4();

        console.error( err );

        res.json( {
            error: err.message,
            message: err.userMessage,
            handled: err.handled || false,
            guid: err.guid,
            stack: err.stack
        } );
    }
function debug( err, req, res, next ) {
        res.status( err.status || 500 );

        err.guid = uuid.v4();

        console.error( err );

        res.json( {
            error: err.message,
            message: err.userMessage,
            handled: err.handled || false,
            guid: err.guid,
            stack: err.stack
        } );
    }
function debug ( err , req , res , next ) { res . status ( err . status || 500 ) ; err . guid = uuid . v4 ( ) ; console . error ( err ) ; res . json ( { error : err . message , message : err . userMessage , handled : err . handled || false , guid : err . guid , stack : err . stack } ) ; }
development error handler will print full error
development error handler will print full error