diff --git a/src/json.hpp b/src/json.hpp index 2abea0fd4..aa85740e6 100644 --- a/src/json.hpp +++ b/src/json.hpp @@ -12781,7 +12781,7 @@ class basic_json // passed iterators must belong to objects if (JSON_UNLIKELY(not first.m_object->is_object() - or not first.m_object->is_object())) + or not last.m_object->is_object())) { JSON_THROW(invalid_iterator::create(202, "iterators first and last must point to objects")); }