fix: decoding of bolt11 invoices with route hints

refs #129
This commit is contained in:
fusion44 2022-07-04 18:45:45 +02:00
parent 100bb80b17
commit d997b17529
No known key found for this signature in database
GPG key ID: 645FA807E935D9D5

View file

@ -334,7 +334,7 @@ class HopHint(BaseModel):
..., description="The public key of the node at the start of the channel."
)
chan_id: int = Query(..., description="The unique identifier of the channel.")
chan_id: str = Query(..., description="The unique identifier of the channel.")
fee_base_msat: int = Query(
..., description="The base fee of the channel denominated in msat."
@ -383,7 +383,7 @@ class RouteHint(BaseModel):
@classmethod
def from_cln_json(cls, h) -> "RouteHint":
hop_hints = [HopHint.from_cln_json(hh) for hh in h.hop_hints]
hop_hints = [HopHint.from_cln_json(hop_hint) for hop_hint in h]
return cls(hop_hints=hop_hints)