@@ -49,7 +49,7 @@ import Pos.Txp.Class (getMemPool, getUtxoView)
4949import qualified Pos.Txp.Holder as Modern
5050import Pos.Txp.Logic (processTx )
5151import Pos.Txp.Types (UtxoView (.. ), localTxs )
52- import Pos.Types (Address , BlockHeader , ChainDifficulty , Coin ,
52+ import Pos.Types (Address , BlockHeader , ChainDifficulty , Coin , HeaderHash ,
5353 TxAux , TxId , Utxo , difficultyL ,
5454 evalUtxoStateT , flattenEpochOrSlot ,
5555 flattenSlotId , prevBlockL , runUtxoStateT ,
@@ -126,7 +126,7 @@ class Monad m => MonadTxHistory m where
126126 default getTxHistory
127127 :: (MonadTrans t , MonadTxHistory m' , t m' ~ m )
128128 => Address -> Maybe (HeaderHash , Utxo ) -> m TxHistoryAnswer
129- getTxHistory = fmap ( fmap lift) <$> getTxHistory
129+ getTxHistory addr = lift . getTxHistory addr
130130
131131 default saveTx :: (MonadTrans t , MonadTxHistory m' , t m' ~ m ) => (TxId , TxAux ) -> m ()
132132 saveTx = lift . saveTx
@@ -149,7 +149,7 @@ deriving instance MonadTxHistory m => MonadTxHistory (WalletWebDB m)
149149
150150-- | Get tx history for Address
151151instance MonadIO m => MonadTxHistory (WalletDB m ) where
152- getTxHistory addr = do
152+ getTxHistory addr _ = do
153153 chain <- WS. getBestChain
154154 utxo <- WS. getOldestUtxo
155155 res <- fmap (fst . fromMaybe (panic " deriveAddrHistory: Nothing" )) $
@@ -158,10 +158,9 @@ instance MonadIO m => MonadTxHistory (WalletDB m) where
158158 pure undefined
159159 saveTx _ = pure ()
160160
161- instance (SscHelpersClass ssc , MonadDB ssc m , MonadThrow m , WithLogger m )
161+ instance (SscHelpersClass ssc , MonadDB ssc m , MonadThrow m , WithLogger m , PC. WithNodeContext ssc m )
162162 => MonadTxHistory (Modern. TxpLDHolder ssc m ) where
163163 getTxHistory addr mInit = do
164- bot <- maybe GS. getBot pure mbot
165164 tip <- GS. getTip
166165
167166 let getGenUtxo = filterUtxoByAddr addr . PC. ncGenesisUtxo <$> PC. getNodeContext
0 commit comments