node-phash icon indicating copy to clipboard operation
node-phash copied to clipboard

how can i catch errors?

Open brandonmp opened this issue 9 years ago • 0 comments

I notice sometimes the library emits an error message, like, premature end of JPEG file. I think the hash turns out OK, and the image looks fine upon visual inspection, but I'd still like to log these errors.

Is there a way to intercept them from the library and handle them? it looks like they just go to stdout, but I don't route my error logging etc. thru stdout, so I'm hoping to avoid having to scrape errors from the console.

brandonmp avatar Nov 28 '16 18:11 brandonmp