Provide proper implementation of isInteger for qtjson

This commit is contained in:
plamot 2017-03-22 00:38:26 +01:00
parent b8b2634ad6
commit 51c916c029

View File

@ -433,7 +433,8 @@ public:
bool isInteger() const
{
return value.isDouble();
//toInt returns the default value (0, 1) if the value is not a whole number
return value.isDouble() && (value.toInt(0) == value.toInt(1));
}
bool isNull() const