X-Git-Url: http://source.bookstackapp.com/bookstack/blobdiff_plain/295cd0160525125bbd7756d7ad07392ae7201cb8..refs/pull/4467/head:/app/Entities/Controllers/BookController.php diff --git a/app/Entities/Controllers/BookController.php b/app/Entities/Controllers/BookController.php index 45989a803..55d28c684 100644 --- a/app/Entities/Controllers/BookController.php +++ b/app/Entities/Controllers/BookController.php @@ -5,6 +5,7 @@ namespace BookStack\Entities\Controllers; use BookStack\Activity\ActivityQueries; use BookStack\Activity\ActivityType; use BookStack\Activity\Models\View; +use BookStack\Activity\Tools\UserEntityWatchOptions; use BookStack\Entities\Models\Bookshelf; use BookStack\Entities\Repos\BookRepo; use BookStack\Entities\Tools\BookContents; @@ -14,7 +15,7 @@ use BookStack\Entities\Tools\ShelfContext; use BookStack\Exceptions\ImageUploadException; use BookStack\Exceptions\NotFoundException; use BookStack\Facades\Activity; -use BookStack\Http\Controllers\Controller; +use BookStack\Http\Controller; use BookStack\References\ReferenceFetcher; use BookStack\Util\SimpleListOptions; use Illuminate\Http\Request; @@ -138,6 +139,7 @@ class BookController extends Controller 'current' => $book, 'bookChildren' => $bookChildren, 'bookParentShelves' => $bookParentShelves, + 'watchOptions' => new UserEntityWatchOptions(user(), $book), 'activity' => $activities->entityActivity($book, 20, 1), 'referenceCount' => $this->referenceFetcher->getPageReferenceCountToEntity($book), ]);