]> BookStack Code Mirror - bookstack/blobdiff - app/Http/Controllers/CommentController.php
Aligned constructors across controller classes
[bookstack] / app / Http / Controllers / CommentController.php
index 4eb56a4b0cd0720cfcc110e5c22662b958231f4b..f8586e269d1c2ec2e475d5cf8bf219e4d4786fe7 100644 (file)
@@ -1,6 +1,7 @@
 <?php namespace BookStack\Http\Controllers;
 
 use Activity;
+use BookStack\Actions\ActivityType;
 use BookStack\Actions\CommentRepo;
 use BookStack\Entities\Page;
 use Illuminate\Http\Request;
@@ -13,7 +14,6 @@ class CommentController extends Controller
     public function __construct(CommentRepo $commentRepo)
     {
         $this->commentRepo = $commentRepo;
-        parent::__construct();
     }
 
     /**
@@ -40,7 +40,6 @@ class CommentController extends Controller
         // Create a new comment.
         $this->checkPermission('comment-create-all');
         $comment = $this->commentRepo->create($page, $request->get('text'), $request->get('parent_id'));
-        Activity::add($page, 'commented_on', $page->book->id);
         return view('comments.comment', ['comment' => $comment]);
     }