X-Git-Url: https://git-public.kairo.at/?p=php-utility-classes.git;a=blobdiff_plain;f=include%2Fclasses%2Frrdstat.php-class;h=0cc03ef556fc62aada4882a69cef84bc2c8d6fdf;hp=bc41408c5515b9b61e4e418b9e41e737a5548ee6;hb=633b21afce66bd8ea1f0a3345173f2a6c33b9389;hpb=b5e79d087cecb530a68d6e3fdb90cf68715350bd diff --git a/include/classes/rrdstat.php-class b/include/classes/rrdstat.php-class index bc41408..0cc03ef 100644 --- a/include/classes/rrdstat.php-class +++ b/include/classes/rrdstat.php-class @@ -286,7 +286,7 @@ class rrdstat { function update($upArray = null) { // feed new data into RRD - if ($this->status != 'ok') { trigger_error('Cannot update non-writeable file', E_USER_WARNING); return 1; } + if ($this->status != 'ok') { trigger_error('Cannot update non-writeable file', E_USER_WARNING); return false; } $upvals = array(); if (isset($this->config_raw['update'])) { if (preg_match('/^\s*function\s+{(.*)}\s*$/is', $this->config_raw['update'], $regs)) { @@ -366,7 +366,7 @@ class rrdstat { $success = false; } else { $success = true; } - return ($return_var == 0); + return $success; } function fetch($cf = 'AVERAGE', $resolution = null, $start = null, $end = null) {