X-Git-Url: http://source.bookstackapp.com/bookstack/blobdiff_plain/bc1302a8d8c9c7facb16b28e1cf1da4409e7ede0..refs/pull/767/head:/app/Repos/CommentRepo.php diff --git a/app/Repos/CommentRepo.php b/app/Repos/CommentRepo.php index d8c57bdb3..7f89e7f8d 100644 --- a/app/Repos/CommentRepo.php +++ b/app/Repos/CommentRepo.php @@ -7,7 +7,8 @@ use BookStack\Entity; * Class CommentRepo * @package BookStack\Repos */ -class CommentRepo { +class CommentRepo +{ /** * @var Comment $comment @@ -39,7 +40,7 @@ class CommentRepo { * @param array $data * @return Comment */ - public function create (Entity $entity, $data = []) + public function create(Entity $entity, $data = []) { $userId = user()->id; $comment = $this->comment->newInstance($data); @@ -81,7 +82,9 @@ class CommentRepo { protected function getNextLocalId(Entity $entity) { $comments = $entity->comments(false)->orderBy('local_id', 'desc')->first(); - if ($comments === null) return 1; + if ($comments === null) { + return 1; + } return $comments->local_id + 1; } -} \ No newline at end of file +}