Skip to content

Commit 41e0713

Browse files
committed
fix: allow null for mercure_publish() retry parameter
1 parent bbfb1b0 commit 41e0713

1 file changed

Lines changed: 2 additions & 1 deletion

File tree

frankenphp.c

Lines changed: 2 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -514,6 +514,7 @@ PHP_FUNCTION(mercure_publish) {
514514
zend_string *data = NULL, *id = NULL, *type = NULL;
515515
zend_bool private = 0;
516516
zend_long retry = 0;
517+
bool retry_is_null = 1;
517518

518519
ZEND_PARSE_PARAMETERS_START(1, 6)
519520
Z_PARAM_ZVAL(topics)
@@ -522,7 +523,7 @@ PHP_FUNCTION(mercure_publish) {
522523
Z_PARAM_BOOL(private)
523524
Z_PARAM_STR_OR_NULL(id)
524525
Z_PARAM_STR_OR_NULL(type)
525-
Z_PARAM_LONG(retry)
526+
Z_PARAM_LONG_OR_NULL(retry, retry_is_null)
526527
ZEND_PARSE_PARAMETERS_END();
527528

528529
if (Z_TYPE_P(topics) != IS_ARRAY && Z_TYPE_P(topics) != IS_STRING) {

0 commit comments

Comments
 (0)