1
0
mirror of https://github.com/BookStackApp/BookStack.git synced 2025-08-09 10:22:51 +03:00

Updated shelf-list view to enforce view permissions for child books

- Aligned shelf-homepage behaviour to match
- Updated testing to cover.

For #2111
This commit is contained in:
Dan Brown
2020-05-12 22:21:45 +01:00
parent d3ec38bee3
commit 9666c8c0f7
4 changed files with 24 additions and 7 deletions

View File

@@ -28,8 +28,10 @@ class BookshelfRepo
*/
public function getAllPaginated(int $count = 20, string $sort = 'name', string $order = 'asc'): LengthAwarePaginator
{
return Bookshelf::visible()->with('visibleBooks')
->orderBy($sort, $order)->paginate($count);
return Bookshelf::visible()
->with('visibleBooks')
->orderBy($sort, $order)
->paginate($count);
}
/**