bitcoinjs / bolt11

A library for encoding and decoding lightning network payment requests as defined in BOLT #11.

Geek Repo:Geek Repo

Github PK Tool:Github PK Tool

minor mistyping of PaymentRequestObject

riperk opened this issue · comments

PaymentRequestObject is defined as having a:

bolt11/payreq.d.ts

Lines 24 to 25 in 5ce112c

satoshis?: number;
millisatoshis?: string;

which is not compatible with nulls:

bolt11/payreq.js

Lines 779 to 780 in 5ce112c

satoshis = null
millisatoshis = null

So either the type should be changed to X | null or should actually use undefined like the type declaration.

Thanks for the report!

Published as 1.2.6