mirror of
https://github.com/aljazceru/nutshell.git
synced 2026-01-10 04:04:19 +01:00
Add FakeWallet invoice features tag for supported payment secret (#609)
This commit is contained in:
@@ -7,6 +7,9 @@ from typing import AsyncGenerator, Dict, List, Optional
|
||||
|
||||
from bolt11 import (
|
||||
Bolt11,
|
||||
Feature,
|
||||
FeatureState,
|
||||
Features,
|
||||
MilliSatoshi,
|
||||
TagChar,
|
||||
Tags,
|
||||
@@ -90,6 +93,7 @@ class FakeWallet(LightningBackend):
|
||||
) -> InvoiceResponse:
|
||||
self.assert_unit_supported(amount.unit)
|
||||
tags = Tags()
|
||||
tags.add(TagChar.features, Features.from_feature_list({Feature.payment_secret: FeatureState.supported}))
|
||||
|
||||
if description_hash:
|
||||
tags.add(TagChar.description_hash, description_hash.hex())
|
||||
|
||||
Reference in New Issue
Block a user