fix #72 - update to Kirby 4.5
This commit is contained in:
parent
cb1f842fc9
commit
44d08b3e21
273 changed files with 678 additions and 54176 deletions
|
|
@ -1132,7 +1132,7 @@ class Str
|
|||
string $string = null,
|
||||
string $separator = null,
|
||||
string $allowed = null,
|
||||
int $maxlength = 128
|
||||
int|false $maxlength = 128
|
||||
): string {
|
||||
$separator ??= static::$defaults['slug']['separator'];
|
||||
$allowed ??= static::$defaults['slug']['allowed'];
|
||||
|
|
@ -1165,7 +1165,11 @@ class Str
|
|||
$string = preg_replace('![^a-z0-9]+$!', '', $string);
|
||||
|
||||
// cut the string after the given maxlength
|
||||
return static::short($string, $maxlength, '');
|
||||
if ($maxlength !== false) {
|
||||
$string = static::short($string, $maxlength, '');
|
||||
}
|
||||
|
||||
return $string;
|
||||
}
|
||||
|
||||
/**
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue