Tpl::display_ajax_return(): provided messages & errors event if is not a success return
This commit is contained in:
parent
8815decc02
commit
38f66c9971
1 changed files with 1 additions and 1 deletions
|
@ -671,7 +671,7 @@ class Tpl {
|
|||
)
|
||||
http_response_code($error_code ? $error_code : 400);
|
||||
|
||||
if (($data['success'] ?? false) && !$keep_messages_on_success) {
|
||||
if (!$keep_messages_on_success) {
|
||||
$data['messages'] = self :: get_messages();
|
||||
if (!$data['messages']) unset($data['messages']);
|
||||
self :: purge_messages();
|
||||
|
|
Loading…
Reference in a new issue