4 * Class CRM_Core_LegacyErrorHandler
6 class CRM_Core_LegacyErrorHandler
{
9 * @param \Civi\Core\Event\UnhandledExceptionEvent $event
12 public static function handleException($event) {
13 $e = $event->exception
;
14 if ($e instanceof CRM_Core_Exception
) {
15 $params = $e->getErrorData();
16 $message = $e->getMessage();
17 $session = CRM_Core_Session
::singleton();
19 htmlspecialchars($message),
20 htmlspecialchars($params['message_title'] ??
ts('Error')),
21 $params['message_type'] ??
'error'