mirror of
https://github.com/shlinkio/shlink.git
synced 2026-03-10 09:13:11 +08:00
Ensured empty string is ignored as the domain during short URL creation
This commit is contained in:
@@ -78,6 +78,12 @@ function getOptionalBoolFromInputFilter(InputFilter $inputFilter, string $fieldN
|
||||
return $value !== null ? (bool) $value : null;
|
||||
}
|
||||
|
||||
function getNonEmptyOptionalValueFromInputFilter(InputFilter $inputFilter, string $fieldName): mixed
|
||||
{
|
||||
$value = $inputFilter->getValue($fieldName);
|
||||
return empty($value) ? null : $value;
|
||||
}
|
||||
|
||||
function arrayToString(array $array, int $indentSize = 4): string
|
||||
{
|
||||
$indent = str_repeat(' ', $indentSize);
|
||||
|
||||
Reference in New Issue
Block a user