summaryrefslogtreecommitdiff
path: root/amount.cc
diff options
context:
space:
mode:
Diffstat (limited to 'amount.cc')
-rw-r--r--amount.cc3
1 files changed, 2 insertions, 1 deletions
diff --git a/amount.cc b/amount.cc
index ccad248b..1ec23926 100644
--- a/amount.cc
+++ b/amount.cc
@@ -980,7 +980,8 @@ amount_t commodity_t::value(const std::time_t moment)
}
if (updater)
- (*updater)(this, moment, age, price);
+ (*updater)(this, moment, age,
+ history.size() > 0 ? (*history.rbegin()).first : 0, price);
return price;
}