diff --git a/src/evo/deterministicmns.cpp b/src/evo/deterministicmns.cpp index ecf57b4ed8785..2e7e5f2250cea 100644 --- a/src/evo/deterministicmns.cpp +++ b/src/evo/deterministicmns.cpp @@ -445,7 +445,7 @@ void CDeterministicMNList::AddMN(const CDeterministicMNCPtr& dmn, bool fBumpTota } } -void CDeterministicMNList::UpdateMN(const CDeterministicMN& oldDmn, const CDeterministicMNStateCPtr& pdmnState) +void CDeterministicMNList::UpdateMN(const CDeterministicMN& oldDmn, const std::shared_ptr& pdmnState) { auto dmn = std::make_shared(oldDmn); auto oldState = dmn->pdmnState; @@ -474,7 +474,7 @@ void CDeterministicMNList::UpdateMN(const CDeterministicMN& oldDmn, const CDeter mnMap = mnMap.set(oldDmn.proTxHash, dmn); } -void CDeterministicMNList::UpdateMN(const uint256& proTxHash, const CDeterministicMNStateCPtr& pdmnState) +void CDeterministicMNList::UpdateMN(const uint256& proTxHash, const std::shared_ptr& pdmnState) { auto oldDmn = mnMap.find(proTxHash); if (!oldDmn) { diff --git a/src/evo/deterministicmns.h b/src/evo/deterministicmns.h index 2201c6338c6b3..d59f8c00274a6 100644 --- a/src/evo/deterministicmns.h +++ b/src/evo/deterministicmns.h @@ -59,7 +59,7 @@ class CDeterministicMN uint256 proTxHash; COutPoint collateralOutpoint; uint16_t nOperatorReward{0}; - CDeterministicMNStateCPtr pdmnState; + std::shared_ptr pdmnState; template inline void SerializationOp(Stream& s, Operation ser_action, bool oldFormat) @@ -340,8 +340,8 @@ class CDeterministicMNList CDeterministicMNList ApplyDiff(const CBlockIndex* pindex, const CDeterministicMNListDiff& diff) const; void AddMN(const CDeterministicMNCPtr& dmn, bool fBumpTotalCount = true); - void UpdateMN(const CDeterministicMN& oldDmn, const CDeterministicMNStateCPtr& pdmnState); - void UpdateMN(const uint256& proTxHash, const CDeterministicMNStateCPtr& pdmnState); + void UpdateMN(const CDeterministicMN& oldDmn, const std::shared_ptr& pdmnState); + void UpdateMN(const uint256& proTxHash, const std::shared_ptr& pdmnState); void UpdateMN(const CDeterministicMN& oldDmn, const CDeterministicMNStateDiff& stateDiff); void RemoveMN(const uint256& proTxHash); @@ -482,7 +482,7 @@ class CDeterministicMNListDiff_OldFormat uint256 blockHash; int nHeight{-1}; std::map addedMNs; - std::map updatedMNs; + std::map> updatedMNs; std::set removedMns; template diff --git a/src/evo/dmnstate.h b/src/evo/dmnstate.h index 34cdd3aa9badb..4521ac6406296 100644 --- a/src/evo/dmnstate.h +++ b/src/evo/dmnstate.h @@ -20,9 +20,6 @@ class UniValue; class CDeterministicMNState; -using CDeterministicMNStatePtr = std::shared_ptr; -using CDeterministicMNStateCPtr = std::shared_ptr; - namespace llmq { class CFinalCommitment; @@ -131,8 +128,6 @@ class CDeterministicMNState std::string ToString() const; void ToJson(UniValue& obj) const; }; -using CDeterministicMNStatePtr = std::shared_ptr; -using CDeterministicMNStateCPtr = std::shared_ptr; class CDeterministicMNStateDiff {