SessionHandler::getInstance()->changeUser(new User(null), true);
$job->perform();
}
+ catch (\Throwable $e) {
+ // gotta catch 'em all
+ $job->fail();
+
+ if ($job->getFailures() <= $job::MAX_FAILURES) {
+ $this->enqueueIn($job, $job->retryAfter());
+ }
+ else {
+ // job failed too often: log
+ \wcf\functions\exception\logThrowable($e);
+ }
+ }
catch (\Exception $e) {
// gotta catch 'em all
$job->fail();
$this->performJob($job);
}
}
+ catch (\Throwable $e) {
+ // job is completely broken: log
+ \wcf\functions\exception\logThrowable($e);
+ }
catch (\Exception $e) {
// job is completely broken: log
\wcf\functions\exception\logThrowable($e);