MoneroCheck fields are optional;

make error messages consistent with rpc
This commit is contained in:
woodser
2019-07-02 20:29:22 -04:00
parent bb82e5f3d2
commit a00c4a9ee5
3 changed files with 42 additions and 22 deletions
+5 -5
View File
@@ -279,9 +279,9 @@ namespace monero {
* Results from checking a transaction key.
*/
struct MoneroCheckTx : public MoneroCheck {
bool inTxPool;
uint64_t numConfirmations;
uint64_t receivedAmount;
boost::optional<bool> inTxPool;
boost::optional<uint64_t> numConfirmations;
boost::optional<uint64_t> receivedAmount;
boost::property_tree::ptree toPropertyTree() const;
};
@@ -290,8 +290,8 @@ namespace monero {
* Results from checking a reserve proof.
*/
struct MoneroCheckReserve : public MoneroCheck {
uint64_t totalAmount;
uint64_t unconfirmedSpentAmount;
boost::optional<uint64_t> totalAmount;
boost::optional<uint64_t> unconfirmedSpentAmount;
boost::property_tree::ptree toPropertyTree() const;
};