mirror of
https://github.com/linuxserver/Heimdall.git
synced 2025-12-03 05:29:53 +09:00
upgrade to laravel 8.0
This commit is contained in:
committed by
Attila Jozsef Kerekes
parent
43f894b58d
commit
27f58c0866
11
vendor/symfony/string/AbstractUnicodeString.php
vendored
11
vendor/symfony/string/AbstractUnicodeString.php
vendored
@@ -162,7 +162,7 @@ abstract class AbstractUnicodeString extends AbstractString
|
||||
public function camel(): parent
|
||||
{
|
||||
$str = clone $this;
|
||||
$str->string = str_replace(' ', '', preg_replace_callback('/\b./u', static function ($m) use (&$i) {
|
||||
$str->string = str_replace(' ', '', preg_replace_callback('/\b.(?![A-Z]{2,})/u', static function ($m) use (&$i) {
|
||||
return 1 === ++$i ? ('İ' === $m[0] ? 'i̇' : mb_strtolower($m[0], 'UTF-8')) : mb_convert_case($m[0], \MB_CASE_TITLE, 'UTF-8');
|
||||
}, preg_replace('/[^\pL0-9]++/u', ' ', $this->string)));
|
||||
|
||||
@@ -366,7 +366,7 @@ abstract class AbstractUnicodeString extends AbstractString
|
||||
|
||||
public function snake(): parent
|
||||
{
|
||||
$str = $this->camel()->title();
|
||||
$str = $this->camel();
|
||||
$str->string = mb_strtolower(preg_replace(['/(\p{Lu}+)(\p{Lu}\p{Ll})/u', '/([\p{Ll}0-9])(\p{Lu})/u'], '\1_\2', $str->string), 'UTF-8');
|
||||
|
||||
return $str;
|
||||
@@ -498,8 +498,11 @@ abstract class AbstractUnicodeString extends AbstractString
|
||||
)|[\p{Cc}\x7F]++)/xu', '', $s);
|
||||
}
|
||||
|
||||
// Non printable characters have been dropped, so wcswidth cannot logically return -1.
|
||||
$width += $this->wcswidth($s);
|
||||
$lineWidth = $this->wcswidth($s);
|
||||
|
||||
if ($lineWidth > $width) {
|
||||
$width = $lineWidth;
|
||||
}
|
||||
}
|
||||
|
||||
return $width;
|
||||
|
||||
Reference in New Issue
Block a user