mirror of
https://github.com/Lastorder-DC/rhymix.git
synced 2026-05-02 00:32:15 +09:00
Fix various warnings in PHP 8.0
This commit is contained in:
parent
f46b41f437
commit
60465fb2db
23 changed files with 65 additions and 55 deletions
|
|
@ -229,7 +229,7 @@ class UA
|
|||
if (preg_match('#Android ([0-9\.]+);(?: ([^;]+) Build/)?#', $ua, $matches))
|
||||
{
|
||||
$result->os_version = $matches[1];
|
||||
$result->device = $matches[2] ?: null;
|
||||
$result->device = isset($matches[2]) ? ($matches[2] ?: null) : null;
|
||||
}
|
||||
}
|
||||
elseif ($matches[1] === 'iPhone' || $matches[1] === 'iPad' || $matches[1] === 'iPod')
|
||||
|
|
@ -358,7 +358,7 @@ class UA
|
|||
if (preg_match('#^([a-zA-Z0-9_-]+)(?:/([0-9]+\\.[0-9]+))?#', $ua, $matches))
|
||||
{
|
||||
$result->browser = ucfirst($matches[1]);
|
||||
$result->version = $matches[2] ?: null;
|
||||
$result->version = isset($matches[2]) ? ($matches[2] ?: null) : null;
|
||||
return $result;
|
||||
}
|
||||
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue