Add more info to throw message in math commands (See #14)

This commit is contained in:
chros
2017-03-07 13:12:18 +00:00
parent 8b6a1ad079
commit 6cb176ada3
+2 -2
View File
@@ -522,7 +522,7 @@ apply_elapsed_greater(const torrent::Object::list_type& args) {
int64_t
apply_math_basic(const std::function<int64_t(int64_t,int64_t)> op, const torrent::Object::list_type& args) {
if (args.size() == 0)
throw torrent::input_error("Wrong argument count.");
throw torrent::input_error("Wrong argument count in apply_math_basic.");
int64_t val = 0;
@@ -546,7 +546,7 @@ apply_math_basic(const std::function<int64_t(int64_t,int64_t)> op, const torrent
int64_t
apply_arith_basic(const std::function<int64_t(int64_t,int64_t)> op, const torrent::Object::list_type& args) {
if (args.size() == 0)
throw torrent::input_error("Wrong argument count.");
throw torrent::input_error("Wrong argument count in apply_arith_basic.");
int64_t val = 0;