Porting "JsonObject equals returns false when numeric values have different classes" to master