mirror of
https://github.com/Karaka-Management/phpOMS.git
synced 2026-01-11 09:48:40 +00:00
phpcs fixes
This commit is contained in:
parent
fb295292be
commit
710ff5f7d3
|
|
@ -369,7 +369,7 @@ final class Complex
|
|||
public function div(int|float|self $value) : self
|
||||
{
|
||||
if (\is_numeric($value)) {
|
||||
return $this->divScalar($value);
|
||||
return $this->divScalar($value);
|
||||
}
|
||||
|
||||
return $this->divComplex($value);
|
||||
|
|
|
|||
|
|
@ -31,21 +31,21 @@ use phpOMS\Views\View;
|
|||
*/
|
||||
final class SocketResponse extends ResponseAbstract implements RenderableInterface
|
||||
{
|
||||
/**
|
||||
* Set response.
|
||||
*
|
||||
* @param array $response Response to set
|
||||
*
|
||||
* @return void
|
||||
*
|
||||
* @since 1.0.0
|
||||
*/
|
||||
public function setResponse(array $response) : void
|
||||
{
|
||||
$this->response = $response;
|
||||
}
|
||||
/**
|
||||
* Set response.
|
||||
*
|
||||
* @param array $response Response to set
|
||||
*
|
||||
* @return void
|
||||
*
|
||||
* @since 1.0.0
|
||||
*/
|
||||
public function setResponse(array $response) : void
|
||||
{
|
||||
$this->response = $response;
|
||||
}
|
||||
|
||||
/**
|
||||
/**
|
||||
* Remove response by ID.
|
||||
*
|
||||
* @param mixed $id Response ID
|
||||
|
|
@ -54,24 +54,24 @@ final class SocketResponse extends ResponseAbstract implements RenderableInterfa
|
|||
*
|
||||
* @since 1.0.0
|
||||
*/
|
||||
public function remove($id) : bool
|
||||
{
|
||||
if (isset($this->response[$id])) {
|
||||
unset($this->response[$id]);
|
||||
public function remove($id) : bool
|
||||
{
|
||||
if (isset($this->response[$id])) {
|
||||
unset($this->response[$id]);
|
||||
|
||||
return true;
|
||||
}
|
||||
return true;
|
||||
}
|
||||
|
||||
return false;
|
||||
}
|
||||
return false;
|
||||
}
|
||||
|
||||
/**
|
||||
/**
|
||||
* {@inheritdoc}
|
||||
*/
|
||||
public function getJsonData() : array
|
||||
{
|
||||
return \json_decode($this->getRaw(), true);
|
||||
}
|
||||
public function getJsonData() : array
|
||||
{
|
||||
return \json_decode($this->getRaw(), true);
|
||||
}
|
||||
|
||||
/**
|
||||
* {@inheritdoc}
|
||||
|
|
|
|||
|
|
@ -0,0 +1,13 @@
|
|||
<?php
|
||||
/**
|
||||
* Orange Management
|
||||
*
|
||||
* PHP Version 8.0
|
||||
*
|
||||
* @package phpOMS\Uri
|
||||
* @copyright Dennis Eichhorn
|
||||
* @license OMS License 1.0
|
||||
* @version 1.0.0
|
||||
* @link https://orange-management.org
|
||||
*/
|
||||
declare(strict_types=1);
|
||||
|
|
@ -402,7 +402,7 @@ final class File extends FileAbstract implements FileInterface
|
|||
return false; // @codeCoverageIgnore
|
||||
}
|
||||
|
||||
\touch($path);
|
||||
\touch($path);
|
||||
|
||||
return true;
|
||||
}
|
||||
|
|
|
|||
|
|
@ -115,7 +115,7 @@ final class SystemUtils
|
|||
\exec('wmic cpu get LoadPercentage', $cpuUsage);
|
||||
$cpuUsage = $cpuUsage[1];
|
||||
} elseif (\stristr(\PHP_OS, 'LINUX') !== false) {
|
||||
$loadavg = \sys_getloadavg();
|
||||
$loadavg = \sys_getloadavg();
|
||||
|
||||
if ($loadavg === false) {
|
||||
return -1;
|
||||
|
|
|
|||
Loading…
Reference in New Issue
Block a user