dmtrKovalenko / odiff

The fastest pixel-by-pixel image visual difference tool in the world.

Geek Repo:Geek Repo

Github PK Tool:Github PK Tool

Handle `no file or directory` UnhandledPromiseRejectionWarning

ssfxate opened this issue · comments

Hey. Thank you for the package. It's a great thing and an oportunity to reduce time to compare images.

Could you please add handling an error when no file found in the baseline directory?

For now I get UnhandledPromiseRejectionWarning, but I would be happy to get it via the result object. Something like this.

result: { match: false, reason: 'ENOENT: no such file or directory', details: filepath }

Thb I'm not so confident in coding to get it done by myself and contribute, that's why I'm asking you about this.

Thank you.