mirror of
https://github.com/librenms/librenms.git
synced 2024-10-07 16:52:45 +00:00
Remove debug globals (#12811)
* Remove $debug global and $vdebug global makes these variables more accessible and protects from collisions. * the on boot set sends application as the first parameter, just handle that * Relocate other debug related functions * Log debug to stdout * Wrong output * remove stupid constants * Fix lint and style issues
This commit is contained in:
@@ -11,6 +11,7 @@
|
||||
*/
|
||||
|
||||
use LibreNMS\Config;
|
||||
use LibreNMS\Util\Debug;
|
||||
use LibreNMS\Util\Number;
|
||||
use LibreNMS\Util\Rewrite;
|
||||
|
||||
@@ -462,9 +463,9 @@ function generate_port_image($args)
|
||||
*/
|
||||
function graph_error($text, $color = [128, 0, 0])
|
||||
{
|
||||
global $vars, $debug;
|
||||
global $vars;
|
||||
|
||||
if (! $debug) {
|
||||
if (! Debug::isEnabled()) {
|
||||
set_image_type();
|
||||
}
|
||||
|
||||
|
Reference in New Issue
Block a user