| @@ 147-161 (lines=15) @@ | ||
| 144 | ||
| 145 | $statusIsSet = false; |
|
| 146 | // Default behaviour. |
|
| 147 | if (isset($status) && $status != '' && $status != 'undefined') { |
|
| 148 | if ($debug > 1) { |
|
| 149 | error_log('Calling set_status('.$status.')', 0); |
|
| 150 | } |
|
| 151 | ||
| 152 | $myLPI->set_status($status); |
|
| 153 | $statusIsSet = true; |
|
| 154 | if ($debug > 1) { |
|
| 155 | error_log('Done calling set_status: checking from memory: '.$myLPI->get_status(false), 0); |
|
| 156 | } |
|
| 157 | } else { |
|
| 158 | if ($debug > 1) { |
|
| 159 | error_log("Status not updated"); |
|
| 160 | } |
|
| 161 | } |
|
| 162 | ||
| 163 | $my_type = $myLPI->get_type(); |
|
| 164 | // Set status to completed for hotpotatoes if score > 80%. |
|
| @@ 325-339 (lines=15) @@ | ||
| 322 | // generic behaviour |
|
| 323 | if (!$statusIsSet && !$statusSignalReceived) { |
|
| 324 | // Default behaviour |
|
| 325 | if (isset($status) && $status != '' && $status != 'undefined') { |
|
| 326 | if ($debug > 1) { |
|
| 327 | error_log('Calling set_status('.$status.')', 0); |
|
| 328 | } |
|
| 329 | ||
| 330 | $myLPI->set_status($status); |
|
| 331 | ||
| 332 | if ($debug > 1) { |
|
| 333 | error_log('Done calling set_status: checking from memory: '.$myLPI->get_status(false), 0); |
|
| 334 | } |
|
| 335 | } else { |
|
| 336 | if ($debug > 1) { |
|
| 337 | error_log("Status not updated"); |
|
| 338 | } |
|
| 339 | } |
|
| 340 | } |
|
| 341 | ||
| 342 | if (isset($time) && $time != '' && $time != 'undefined') { |
|