update lock clucknut
All checks were successful
All checks were successful
This commit is contained in:
4
vendor/symfony/uid/Uuid.php
vendored
4
vendor/symfony/uid/Uuid.php
vendored
@@ -32,13 +32,13 @@ public function __construct(string $uuid, bool $checkVariant = false)
|
||||
$type = preg_match('{^[0-9a-f]{8}(?:-[0-9a-f]{4}){3}-[0-9a-f]{12}$}Di', $uuid) ? (int) $uuid[14] : false;
|
||||
|
||||
if (false === $type || (static::TYPE ?: $type) !== $type) {
|
||||
throw new \InvalidArgumentException(\sprintf('Invalid UUID%s: "%s".', static::TYPE ? 'v'.static::TYPE : '', $uuid));
|
||||
throw new \InvalidArgumentException(\sprintf('Invalid UUID%s.', static::TYPE ? 'v'.static::TYPE : ''));
|
||||
}
|
||||
|
||||
$this->uid = strtolower($uuid);
|
||||
|
||||
if ($checkVariant && !\in_array($this->uid[19], ['8', '9', 'a', 'b'], true)) {
|
||||
throw new \InvalidArgumentException(\sprintf('Invalid UUID%s: "%s".', static::TYPE ? 'v'.static::TYPE : '', $uuid));
|
||||
throw new \InvalidArgumentException(\sprintf('Invalid UUID%s.', static::TYPE ? 'v'.static::TYPE : ''));
|
||||
}
|
||||
}
|
||||
|
||||
|
||||
Reference in New Issue
Block a user