fix(bolt11): print error

This commit is contained in:
P. Reis 2024-06-17 18:15:42 -03:00
parent 7a29c349e8
commit c6425ad7ff

View file

@ -7,7 +7,8 @@ function getAmount(invoice: string | undefined): string | undefined {
try {
const decoded = bolt11.decode(invoice);
return decoded?.millisatoshis ?? undefined;
} catch {
} catch (e) {
console.log(e);
return;
}
}