diff --git a/src/wallet/spend.cpp b/src/wallet/spend.cpp index c7c41f5d0f1..1e0ac8f0428 100644 --- a/src/wallet/spend.cpp +++ b/src/wallet/spend.cpp @@ -223,7 +223,7 @@ void CoinsResult::Erase(const std::unordered_set GetEffectiveTotalAmount() {return total_effective_amount; } + std::optional GetEffectiveTotalAmount() { return total_effective_amount; } private: /** Sum of all available coins raw value */ CAmount total_amount{0}; /** Sum of all available coins effective value (each output value minus fees required to spend it) */ - std::optional total_effective_amount{0}; + std::optional total_effective_amount; }; struct CoinFilterParams {