]> BookStack Code Mirror - bookstack/blobdiff - app/Http/Controllers/SearchController.php
Fixes "bookshelf" pt_BR translation in "activities"
[bookstack] / app / Http / Controllers / SearchController.php
index 49f9885adb24c1bb438f5b95f6cd20fd0f7937a7..4402b7caf310e0f142a72f1fad724d4ebe34d432 100644 (file)
@@ -1,8 +1,8 @@
 <?php namespace BookStack\Http\Controllers;
 
-use BookStack\Repos\EntityRepo;
-use BookStack\Services\SearchService;
-use BookStack\Services\ViewService;
+use BookStack\Actions\ViewService;
+use BookStack\Entities\EntityRepo;
+use BookStack\Entities\SearchService;
 use Illuminate\Http\Request;
 
 class SearchController extends Controller
@@ -97,7 +97,7 @@ class SearchController extends Controller
             $entities = $this->searchService->searchEntities($searchTerm, 'all', 1, 20, $permission)['results'];
         } else {
             $entityNames = $entityTypes->map(function ($type) {
-                return 'BookStack\\' . ucfirst($type);
+                return 'BookStack\\' . ucfirst($type); // TODO - Extract this elsewhere, too specific and stringy
             })->toArray();
             $entities = $this->viewService->getPopular(20, 0, $entityNames, $permission);
         }