Changed double-quotes to single
This commit is contained in:
parent
88870d18be
commit
f689faca99
|
@ -1719,29 +1719,29 @@ class Database
|
||||||
*/
|
*/
|
||||||
public function processlist(): array
|
public function processlist(): array
|
||||||
{
|
{
|
||||||
$ret = $this->p("SHOW PROCESSLIST");
|
$ret = $this->p('SHOW PROCESSLIST');
|
||||||
$data = $this->toArray($ret);
|
$data = $this->toArray($ret);
|
||||||
|
|
||||||
$processes = 0;
|
$processes = 0;
|
||||||
$states = [];
|
$states = [];
|
||||||
foreach ($data as $process) {
|
foreach ($data as $process) {
|
||||||
$state = trim($process["State"]);
|
$state = trim($process['State']);
|
||||||
|
|
||||||
// Filter out all non blocking processes
|
// Filter out all non blocking processes
|
||||||
if (!in_array($state, ["", "init", "statistics", "updating"])) {
|
if (!in_array($state, ['', 'init', 'statistics', 'updating'])) {
|
||||||
++$states[$state];
|
++$states[$state];
|
||||||
++$processes;
|
++$processes;
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|
||||||
$statelist = "";
|
$statelist = '';
|
||||||
foreach ($states as $state => $usage) {
|
foreach ($states as $state => $usage) {
|
||||||
if ($statelist != "") {
|
if ($statelist != '') {
|
||||||
$statelist .= ", ";
|
$statelist .= ', ';
|
||||||
}
|
}
|
||||||
$statelist .= $state . ": " . $usage;
|
$statelist .= $state . ': ' . $usage;
|
||||||
}
|
}
|
||||||
return (["list" => $statelist, "amount" => $processes]);
|
return (['list' => $statelist, 'amount' => $processes]);
|
||||||
}
|
}
|
||||||
|
|
||||||
/**
|
/**
|
||||||
|
|
Loading…
Reference in a new issue