]> git.ipfire.org Git - thirdparty/bacula.git/commitdiff
baculum: Fix undefined property error in run job API endpoint if level value is not...
authorMarcin Haba <marcin.haba@bacula.pl>
Sun, 7 Feb 2021 14:43:44 +0000 (15:43 +0100)
committerMarcin Haba <marcin.haba@bacula.pl>
Sun, 7 Feb 2021 14:43:44 +0000 (15:43 +0100)
gui/baculum/protected/API/Pages/API/JobRun.php

index 1a98a6255561ddf53b38a1edf89d9458f633bf00..86c781e503e5445816b54d2188921401ed039035 100644 (file)
@@ -113,7 +113,7 @@ class JobRun extends BaculumAPIServer {
                        }
                }
 
-               $is_valid_level = $this->getModule('misc')->isValidJobLevel($params->level);
+               $is_valid_level = $this->getModule('misc')->isValidJobLevel($level);
                if(!$is_valid_level) {
                        $this->output = JobError::MSG_ERROR_INVALID_JOBLEVEL;
                        $this->error = JobError::ERROR_INVALID_JOBLEVEL;