I'm not sure that showing such error messages to actual users is a good idea. They are leaking information about your server and can help an attacker. You should consider logging those but not showing any error details to users. That being said: I'm not sure if there is an existing module that would automatically convert those errors into nicer log lines. On the other hand - since you are the only one who could tell the person who is looking at the log files how to fix the problems, maybe it would be best to do the mapping yourself.
On Sunday, February 23, 2014 4:52:00 AM UTC-8, Benjamin Pasero wrote: > > Hi, > > I am wondering if there is any module out there that could be plugged into > the server to convert error messages into more friendly format? Currently I > pass errors to the user and he will end up seeing stuff like: > > Error: EBUSY, unlink 'D:\home\site\wwwroot\images\images.zip > Error: ENOTEMPTY, rmdir 'D:\home\site\wwwroot\webshare\includes' > Error: EBUSY, open 'D:\home\site\wwwroot\wp-content\themes\cd\functions.php > > Would be nice to have a middleware that understands all possible nodejs > errors and converts them into a more friendly format (e.g. "Unable to > delete folder XY because it is not empty..."). > Ben > -- -- Job Board: http://jobs.nodejs.org/ Posting guidelines: https://github.com/joyent/node/wiki/Mailing-List-Posting-Guidelines You received this message because you are subscribed to the Google Groups "nodejs" group. To post to this group, send email to [email protected] To unsubscribe from this group, send email to [email protected] For more options, visit this group at http://groups.google.com/group/nodejs?hl=en?hl=en --- You received this message because you are subscribed to the Google Groups "nodejs" group. To unsubscribe from this group and stop receiving emails from it, send an email to [email protected]. For more options, visit https://groups.google.com/groups/opt_out.
