Skip to content

Commit 59b6f7c

Browse files
fix: hardcoded script type saved in datastore
1 parent 10e6fe2 commit 59b6f7c

File tree

1 file changed

+2
-2
lines changed
  • app/src/main/java/org/bitcoindevkit/devkitwallet/domain

1 file changed

+2
-2
lines changed

app/src/main/java/org/bitcoindevkit/devkitwallet/domain/Wallet.kt

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -238,7 +238,7 @@ class Wallet private constructor(
238238
.setId(walletId)
239239
.setName(newWalletConfig.name)
240240
.setNetwork(newWalletConfig.network.intoProto())
241-
.setScriptType(ActiveWalletScriptType.P2WPKH)
241+
.setScriptType(newWalletConfig.scriptType)
242242
.setDescriptor(descriptor.toStringWithSecret())
243243
.setChangeDescriptor(changeDescriptor.toStringWithSecret())
244244
.setRecoveryPhrase(mnemonic.toString())
@@ -318,7 +318,7 @@ class Wallet private constructor(
318318
.setId(walletId)
319319
.setName(recoverWalletConfig.name)
320320
.setNetwork(recoverWalletConfig.network.intoProto())
321-
.setScriptType(ActiveWalletScriptType.P2WPKH)
321+
.setScriptType(recoverWalletConfig.scriptType)
322322
.setDescriptor(descriptor.toStringWithSecret())
323323
.setChangeDescriptor(changeDescriptor.toStringWithSecret())
324324
.setRecoveryPhrase(mnemonic.toString())

0 commit comments

Comments
 (0)