Skip to content

Commit fe4a96f

Browse files
committed
Fix "strtolower(): Passing null to parameter #1 ($string) of type string is deprecated" on PHP >= 8.4
1 parent def2400 commit fe4a96f

File tree

1 file changed

+1
-1
lines changed

1 file changed

+1
-1
lines changed

wp-includes/sqlite-ast/class-wp-sqlite-driver.php

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -2925,7 +2925,7 @@ private function execute_set_system_variable_statement(
29252925
* SET updatable_views_with_limit = OFF; ERROR 1231 (42000)
29262926
* SET updatable_views_with_limit = false; SELECT @@updatable_views_with_limit; -> NO
29272927
*/
2928-
$lowercase_value = strtolower( $value );
2928+
$lowercase_value = null === $value ? null : strtolower( $value );
29292929
if ( 'on' === $lowercase_value || 'off' === $lowercase_value ) {
29302930
$value = 'on' === $lowercase_value ? 1 : 0;
29312931
}

0 commit comments

Comments
 (0)