Update handling of value assignment when 'jsonelem' is not set.
- Adjusted code to assign $output directly to 'value' if 'jsonelem' is not set.
This commit is contained in:
parent
7c79ea3b6b
commit
226ec5c6a1
@ -16,6 +16,8 @@ if($_SERVER["REQUEST_URI"] == '/metrics') {
|
|||||||
}
|
}
|
||||||
if(isset($c['jsonelem'])) {
|
if(isset($c['jsonelem'])) {
|
||||||
$c['value'] = getArrayValue($c['jsonelem'], json_decode($output, true));
|
$c['value'] = getArrayValue($c['jsonelem'], json_decode($output, true));
|
||||||
|
} else {
|
||||||
|
$c['value'] = $output;
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|
||||||
|
Loading…
Reference in New Issue
Block a user