Which Lace surface?
Browser extension (Chrome)
Version
Lace 2.2.0
What happened?
Calling the Midnight connector API with makeTransfer([output]) fails before the confirmation screen:
Cannot read properties of undefined (reading 'sender')
The connector API defines the second options argument as optional. The same transfer works when it is supplied explicitly:
await walletApi.makeTransfer(outputs, { payFees: true });
The extension appends its sender context after the arguments provided by the dApp. When options is omitted, that context reaches makeTransfer as its second argument, but the current implementation expects it as the third argument.
What did you expect to happen?
makeTransfer([output]) should use the default payFees: true behavior and open the transaction confirmation screen.
Steps to reproduce
- Connect a Midnight dApp to Lace on Preprod.
- Call
walletApi.makeTransfer([output]) without an options argument.
- Observe the error before transaction confirmation.
- Call
walletApi.makeTransfer([output], { payFees: true }).
- Observe that the confirmation screen opens normally.
Environment
- Lace browser extension 2.2.0
- Chromium
- Midnight Preprod
@midnight-ntwrk/dapp-connector-api 4.0.1
Logs, screenshots, or additional context
The API type declares options as optional, documents payFees as true by default, and the package README demonstrates the one-argument call. balanceSealedTransaction and balanceUnsealedTransaction already handle the sender context arriving in the optional-options position.
Which Lace surface?
Browser extension (Chrome)
Version
Lace 2.2.0
What happened?
Calling the Midnight connector API with
makeTransfer([output])fails before the confirmation screen:The connector API defines the second
optionsargument as optional. The same transfer works when it is supplied explicitly:The extension appends its sender context after the arguments provided by the dApp. When
optionsis omitted, that context reachesmakeTransferas its second argument, but the current implementation expects it as the third argument.What did you expect to happen?
makeTransfer([output])should use the defaultpayFees: truebehavior and open the transaction confirmation screen.Steps to reproduce
walletApi.makeTransfer([output])without an options argument.walletApi.makeTransfer([output], { payFees: true }).Environment
@midnight-ntwrk/dapp-connector-api4.0.1Logs, screenshots, or additional context
The API type declares
optionsas optional, documentspayFeesastrueby default, and the package README demonstrates the one-argument call.balanceSealedTransactionandbalanceUnsealedTransactionalready handle the sender context arriving in the optional-options position.