Fixed mixed response from event datatables

This commit is contained in:
Calvo 2021-03-25 13:20:30 +01:00
parent 00375710c2
commit d9d98fe1e3
1 changed files with 5 additions and 0 deletions

View File

@ -415,6 +415,11 @@ if (is_ajax()) {
]
);
$response = ob_get_clean();
// Clean output buffer.
while (ob_get_level() !== 0) {
ob_end_clean();
}
} catch (Exception $e) {
echo json_encode(
['error' => $e->getMessage()]