eee
This commit is contained in:
@@ -22,14 +22,9 @@ class Environmental
|
||||
*/
|
||||
public function isMac(): bool
|
||||
{
|
||||
$output = strtolower(PHP_OS | PHP_OS_FAMILY);
|
||||
if (str_contains('mac', $output)) {
|
||||
return true;
|
||||
} else if (str_contains('darwin', $output)) {
|
||||
return true;
|
||||
} else {
|
||||
return false;
|
||||
}
|
||||
$os = strtolower(PHP_OS);
|
||||
|
||||
return str_contains($os, 'mac') || str_contains($os, 'darwin');
|
||||
}
|
||||
|
||||
|
||||
@@ -38,11 +33,7 @@ class Environmental
|
||||
*/
|
||||
#[Pure] public function isLinux(): bool
|
||||
{
|
||||
if (!static::isMac()) {
|
||||
return true;
|
||||
} else {
|
||||
return false;
|
||||
}
|
||||
return PHP_OS_FAMILY === 'Linux' || strtolower(PHP_OS) === 'linux';
|
||||
}
|
||||
|
||||
}
|
||||
|
||||
Reference in New Issue
Block a user