diff --git a/lib/wallet/api/http/Cardano/Wallet/Api/Http/Shelley/Server.hs b/lib/wallet/api/http/Cardano/Wallet/Api/Http/Shelley/Server.hs index 81f0268b9f5..005c89ee61f 100644 --- a/lib/wallet/api/http/Cardano/Wallet/Api/Http/Shelley/Server.hs +++ b/lib/wallet/api/http/Cardano/Wallet/Api/Http/Shelley/Server.hs @@ -2961,12 +2961,20 @@ constructSharedTransaction handler $ W.readRewardAccount @((SharedState n SharedKey)) db pure $ Just (action, path) + pathForWithdrawal <- case withdrawal of + WithdrawalSelf _ _ _ -> do + (_, _, path) <- + handler $ W.readRewardAccount @((SharedState n SharedKey)) db + pure $ Just path + _ -> + pure Nothing + pure $ ApiConstructTransaction { transaction = balancedTx , coinSelection = mkApiCoinSelection deposits refunds delCertsWithPath md - (unsignedTx outs apiDecoded (snd <$> delCertsWithPath)) + (unsignedTx outs apiDecoded pathForWithdrawal) , fee = apiDecoded ^. #fee } where