1
0
mirror of https://github.com/vrana/adminer.git synced 2025-08-08 07:36:44 +02:00

Explicitly mark nullable params (thanks to @dg)

This commit is contained in:
Jakub Vrana
2025-04-01 19:09:46 +02:00
parent 634b0aaacf
commit 01ea001f22
5 changed files with 7 additions and 7 deletions

View File

@@ -173,7 +173,7 @@ function hidden_fields_get(): void {
* @param Field $field
* @param mixed $value string|array
*/
function enum_input(string $type, string $attrs, array $field, $value, string $empty = null): string {
function enum_input(string $type, string $attrs, array $field, $value, ?string $empty = null): string {
preg_match_all("~'((?:[^']|'')*)'~", $field["length"], $matches);
$return = ($empty !== null ? "<label><input type='$type'$attrs value='$empty'" . ((is_array($value) ? in_array($empty, $value) : $value === $empty) ? " checked" : "") . "><i>" . lang('empty') . "</i></label>" : "");
foreach ($matches[1] as $i => $val) {