Closed stheine closed 2 years ago
The error details are already being passed with that NodeClamError object as data.err
as well as the details of the file in data.file
.
So, in the example for the PR you submitted:
try {
await clam.isInfected('some_file.txt');
} catch (err) {
console.error(err, err.data.err, err.data.file);
}
ok, thanks, I didn't realize that handling in the NodeClamError
.
then please drop my PR.
thanks for the quick answer.
It's not your fault--it's not documented. Documenting it in the README would be a great PR, though. 😉 😉
Hi @kylefarris ,
it would be great, if you could merge and release my PR. this is needed, as there are situations when I need to know the TCP Socket error details, eg. when the clamd returns
INSTREAM size limit exceeded. ERROR
(file size exceeding MaxFileSize).Regards stheine