X-Git-Url: https://delta.frontaccounting.com/gitweb/?a=blobdiff_plain;f=includes%2Fsession.inc;h=9089c693111ead3c2a6a29688c74afb378ddfae4;hb=741ca0d6225c9c0dd046b28deaa957368b82b24a;hp=34e01cd214a56260a76802006cd53d6a30fcde6f;hpb=c09be0dad6b05131e240349a375af7a4b7bf3444;p=fa-stable.git diff --git a/includes/session.inc b/includes/session.inc index 34e01cd2..9089c693 100644 --- a/includes/session.inc +++ b/includes/session.inc @@ -15,9 +15,9 @@ // Fatal errors are not send to error_handler, // so we must check the output if ($text && preg_match('/\bFatal error(<.*?>)?:(.*)/i', $text, $m)) { - $Ajax->aCommands = array(); // Don't update page on errors - - $messages[] = array(E_ERROR, $m[0], null, null); + $Ajax->aCommands = array(); // Don't update page via ajax on errors + $text = preg_replace('/\bFatal error(<.*?>)?:(.*)/i','', $text); + $messages[] = array(E_ERROR, $m[2], null, null); } $Ajax->run(); return in_ajax() ? fmt_errors() : ($before_box.fmt_errors().$text);