Skip to content

Commit a0689c2

Browse files
committed
ext/mysqli: Use zval_is_true() instead of converting to boolean
1 parent c789e9c commit a0689c2

File tree

1 file changed

+1
-2
lines changed

1 file changed

+1
-2
lines changed

ext/mysqli/mysqli.c

Lines changed: 1 addition & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -316,8 +316,7 @@ static int mysqli_object_has_property(zend_object *object, zend_string *name, in
316316
zval rv;
317317
zval *value = mysqli_read_property(object, name, BP_VAR_IS, cache_slot, &rv);
318318
if (value != &EG(uninitialized_zval)) {
319-
convert_to_boolean(value);
320-
has_property = Z_TYPE_P(value) == IS_TRUE;
319+
has_property = zval_is_true(value);
321320
}
322321
break;
323322
}

0 commit comments

Comments
 (0)