Minor tweaks

This commit is contained in:
Djamil Legato
2019-06-04 12:55:10 -07:00
parent f4d5ccf731
commit 616a45a76b
2 changed files with 5 additions and 6 deletions

View File

@@ -1541,13 +1541,12 @@ class AdminController extends AdminBaseController
$response = Utils::sortArrayByKey($response, $sortby, $order);
$temp_array = [];
foreach ($response as $filename => $item) {
$temp_array[$item['type']][$filename] = $item;
foreach ($response as $index => $item) {
$temp_array[$item['type']][$index] = $item;
}
$response = Utils::arrayFlatten(Utils::sortArrayByArray($temp_array, $filter_type));
$sorted = Utils::sortArrayByArray($temp_array, $filter_type);
$response = Utils::arrayFlatten($sorted);
return [$status, $this->admin::translate($msg ?? 'PLUGIN_ADMIN.NO_ROUTE_PROVIDED'), $response, $path];
}