Skip to content

Commit fb8201a

Browse files
committed
chore: add description_hash to LnbitsBackendInvoice::requestInvoice
1 parent a1ddf72 commit fb8201a

File tree

2 files changed

+2
-3
lines changed

2 files changed

+2
-3
lines changed

src/Invoice/Domain/BackendInvoice/LnbitsBackendInvoice.php

Lines changed: 1 addition & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -5,7 +5,6 @@
55
namespace PhpLightning\Invoice\Domain\BackendInvoice;
66

77
use PhpLightning\Invoice\Domain\Http\HttpApiInterface;
8-
98
use PhpLightning\Shared\Transfer\InvoiceTransfer;
109

1110
final class LnbitsBackendInvoice implements BackendInvoiceInterface
@@ -27,7 +26,7 @@ public function requestInvoice(int $satsAmount, string $metadata = ''): InvoiceT
2726
'out' => false,
2827
'amount' => $satsAmount,
2928
'unhashed_description' => bin2hex($metadata),
30-
// 'description_hash' => hash('sha256', $metadata),
29+
'description_hash' => hash('sha256', $metadata),
3130
];
3231

3332
$response = $this->httpApi->postRequestInvoice(

tests/Feature/InvoiceFacadeTest.php

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -66,7 +66,7 @@ private function bootstrapGacela(): void
6666
Gacela::bootstrap(__DIR__, static function (GacelaConfig $config): void {
6767
$config->resetInMemoryCache();
6868
$config->addAppConfigKeyValues(
69-
(new LightningConfig())
69+
(new LightningConfig()) // @phpstan-ignore-line
7070
->setCallbackUrl('https://callback.url/receiver')
7171
->setDomain('domain.com')
7272
->setReceiver('receiver')

0 commit comments

Comments
 (0)