]> BookStack Code Mirror - bookstack/blobdiff - app/Repos/ChapterRepo.php
Added initial translation into German (formal)
[bookstack] / app / Repos / ChapterRepo.php
index c12a9f0f206811eec5b14dd1e27e04f20ccf5275..96f5b2d1ea75d9c47858988b77d4489f3351be11 100644 (file)
@@ -98,8 +98,8 @@ class ChapterRepo extends EntityRepo
     {
         $chapter = $this->chapter->newInstance($input);
         $chapter->slug = $this->findSuitableSlug($chapter->name, $book->id);
-        $chapter->created_by = auth()->user()->id;
-        $chapter->updated_by = auth()->user()->id;
+        $chapter->created_by = user()->id;
+        $chapter->updated_by = user()->id;
         $chapter = $book->chapters()->save($chapter);
         $this->permissionService->buildJointPermissionsForEntity($chapter);
         return $chapter;