Skip to content

Commit 5a85e7c

Browse files
committed
Make get_decoded_payment_request return an InvoiceData type.
It's always returning InvoiceData under the hood anyway and the PaymentRequestData type isn't very helpful to callers.
1 parent ab9da90 commit 5a85e7c

1 file changed

Lines changed: 2 additions & 3 deletions

File tree

lightspark/lightspark_client.py

Lines changed: 2 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -32,6 +32,7 @@
3232
from lightspark.objects.IncomingPayment import from_json as IncomingPayment_from_json
3333
from lightspark.objects.Invoice import Invoice
3434
from lightspark.objects.Invoice import from_json as Invoice_from_json
35+
from lightspark.objects.InvoiceData import InvoiceData
3536
from lightspark.objects.InvoiceData import from_json as InvoiceData_from_json
3637
from lightspark.objects.InvoiceType import InvoiceType
3738
from lightspark.objects.LightningFeeEstimateOutput import (
@@ -376,9 +377,7 @@ def get_current_account(
376377
)
377378
return Account_from_json(self._requester, json["current_account"])
378379

379-
def get_decoded_payment_request(
380-
self, encoded_payment_request: str
381-
) -> PaymentRequestData:
380+
def get_decoded_payment_request(self, encoded_payment_request: str) -> InvoiceData:
382381
logger.info(
383382
"Decoding payment request starting with %s...",
384383
encoded_payment_request[0:10],

0 commit comments

Comments
 (0)