1
0
mirror of https://github.com/BookStackApp/BookStack.git synced 2025-07-28 17:02:04 +03:00

Applied another round of static analysis updates

This commit is contained in:
Dan Brown
2021-11-22 23:33:55 +00:00
parent 1bf59f434b
commit 024924eef3
21 changed files with 96 additions and 57 deletions

View File

@ -75,7 +75,7 @@ class BookshelfApiController extends ApiController
$shelf = Bookshelf::visible()->with([
'tags', 'cover', 'createdBy', 'updatedBy', 'ownedBy',
'books' => function (BelongsToMany $query) {
$query->visible()->get(['id', 'name', 'slug']);
$query->scopes('visible')->get(['id', 'name', 'slug']);
},
])->findOrFail($id);