mirror of
https://github.com/moodle/moodle.git
synced 2025-04-21 00:12:56 +02:00
MDL-28179 make failed event hander error message much more useful.
This commit is contained in:
parent
81f8e0f8a0
commit
99fa9745c4
@ -345,7 +345,11 @@ function events_process_queued_handler($qhandler) {
|
||||
} catch (Exception $e) {
|
||||
// the problem here is that we do not want one broken handler to stop all others,
|
||||
// cron handlers are very tricky because the needed data might have been deleted before the cron execution
|
||||
$errormessage = "Handler function of component $handler->component: $handler->handlerfunction threw exception :".$e->getMessage();
|
||||
$errormessage = "Handler function of component $handler->component: $handler->handlerfunction threw exception :" .
|
||||
$e->getMessage() . "\n" . format_backtrace($e->getTrace(), true);
|
||||
if (!empty($e->debuginfo)) {
|
||||
$errormessage .= $e->debuginfo;
|
||||
}
|
||||
}
|
||||
|
||||
//dispatching failed
|
||||
|
Loading…
x
Reference in New Issue
Block a user