X-Git-Url: https://git.mxchange.org/?a=blobdiff_plain;f=mod%2Fmsearch.php;h=00a72ea9f72171f75470ae3042fd7c7109192057;hb=e56e543a791289e27b5f0850a85f441773167447;hp=d29a2fc6472bd376849e527f55079d1ce4932a34;hpb=e56a53647bd5469551bf4f9ef2df50a5dd16b943;p=friendica.git diff --git a/mod/msearch.php b/mod/msearch.php index d29a2fc647..00a72ea9f7 100644 --- a/mod/msearch.php +++ b/mod/msearch.php @@ -20,6 +20,7 @@ */ use Friendica\App; +use Friendica\Core\System; use Friendica\Database\DBA; use Friendica\DI; use Friendica\Model\User; @@ -37,8 +38,7 @@ function msearch_post(App $a) if (!strlen($search)) { $output = ['total' => 0, 'items_page' => $perpage, 'page' => $page, 'results' => $results]; - echo json_encode($output); - exit(); + System::jsonExit($output); } $total = 0; @@ -60,7 +60,5 @@ function msearch_post(App $a) $output = ['total' => $total, 'items_page' => $perpage, 'page' => $page, 'results' => $results]; - echo json_encode($output); - - exit(); + System::jsonExit($output); }