mirror of
https://github.com/wownero/wownero-cpp.git
synced 2026-10-18 23:58:59 +02:00
MoneroOutput::merge() impl
This commit is contained in:
@@ -307,6 +307,11 @@ namespace monero {
|
||||
|
||||
void MoneroOutput::merge(const shared_ptr<MoneroOutput>& self, const shared_ptr<MoneroOutput>& other) {
|
||||
cout << "MoneroOutput::merge()" << endl;
|
||||
throw runtime_error("Not implemented");
|
||||
if (this != self.get()) throw runtime_error("this != self");
|
||||
if (self == other) return;
|
||||
if (keyImage == boost::none) keyImage = other->keyImage;
|
||||
else if (other->keyImage != boost::none) keyImage.get()->merge(keyImage.get(), other->keyImage.get());
|
||||
amount = MoneroUtils::reconcile(amount, other->amount);
|
||||
index = MoneroUtils::reconcile(index, other->index);
|
||||
}
|
||||
}
|
||||
|
||||
Reference in New Issue
Block a user