]> BookStack Code Mirror - bookstack/commitdiff
Perms: Fixed some issues made when adding transactions 5689/head
authorDan Brown <redacted>
Sun, 6 Jul 2025 21:52:06 +0000 (22:52 +0100)
committerDan Brown <redacted>
Sun, 6 Jul 2025 21:52:06 +0000 (22:52 +0100)
app/Entities/Repos/BookshelfRepo.php
app/Entities/Repos/ChapterRepo.php

index 5d4d604bc309afdbc08c3a04864f1158fb14f87a..8e60f58c42f0c4d1c735b90fe41b962e32347765 100644 (file)
@@ -30,6 +30,7 @@ class BookshelfRepo
             $this->baseRepo->updateCoverImage($shelf, $input['image'] ?? null);
             $this->updateBooks($shelf, $bookIds);
             Activity::add(ActivityType::BOOKSHELF_CREATE, $shelf);
+            return $shelf;
         }))->run();
     }
 
index 2ab6e671f6d5679b3d293dbc72804c113d2b5c38..6503e63cfafc5912a886131ab089b169358ecbeb 100644 (file)
@@ -37,6 +37,8 @@ class ChapterRepo
             Activity::add(ActivityType::CHAPTER_CREATE, $chapter);
 
             $this->baseRepo->sortParent($chapter);
+
+            return $chapter;
         }))->run();
     }