Skip to content

Commit 73190c1

Browse files
committed
wallet: Create a SilentPaymentsSPKM by default
1 parent 958d9a6 commit 73190c1

File tree

1 file changed

+7
-0
lines changed

1 file changed

+7
-0
lines changed

src/wallet/wallet.cpp

+7
Original file line numberDiff line numberDiff line change
@@ -3727,6 +3727,13 @@ void CWallet::SetupDescriptorScriptPubKeyMans()
37273727
master_key.SetSeed(seed_key);
37283728

37293729
SetupDescriptorScriptPubKeyMans(master_key);
3730+
3731+
// Also setup a SilentPaymentsSPKM
3732+
auto sp_spkm = std::unique_ptr<SilentPaymentsSPKM>(new SilentPaymentsSPKM(*this, m_keypool_size, master_key));
3733+
uint256 id = sp_spkm->GetID();
3734+
AddScriptPubKeyMan(id, std::move(sp_spkm));
3735+
AddActiveScriptPubKeyMan(id, OutputType::SILENT_PAYMENT, /*internal=*/false);
3736+
AddActiveScriptPubKeyMan(id, OutputType::SILENT_PAYMENT, /*internal=*/true);
37303737
} else {
37313738
ExternalSigner signer = ExternalSignerScriptPubKeyMan::GetExternalSigner();
37323739

0 commit comments

Comments
 (0)