Skip to content

Commit e19fc20

Browse files
committed
Optimize sprintf() calls for PHP 8.4
1 parent 1c045fc commit e19fc20

1 file changed

Lines changed: 2 additions & 2 deletions

File tree

HtmlExtension.php

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -96,15 +96,15 @@ public static function htmlClasses(...$args): string
9696
} elseif (\is_array($arg)) {
9797
foreach ($arg as $class => $condition) {
9898
if (!\is_string($class)) {
99-
throw new RuntimeError(sprintf('The html_classes function argument %d (key %d) should be a string, got "%s".', $i, $class, \gettype($class)));
99+
throw new RuntimeError(\sprintf('The html_classes function argument %d (key %d) should be a string, got "%s".', $i, $class, \gettype($class)));
100100
}
101101
if (!$condition) {
102102
continue;
103103
}
104104
$classes[] = $class;
105105
}
106106
} else {
107-
throw new RuntimeError(sprintf('The html_classes function argument %d should be either a string or an array, got "%s".', $i, \gettype($arg)));
107+
throw new RuntimeError(\sprintf('The html_classes function argument %d should be either a string or an array, got "%s".', $i, \gettype($arg)));
108108
}
109109
}
110110

0 commit comments

Comments
 (0)