diff --git a/src/Comment.php b/src/Comment.php index 14f1f9c..ebacf3b 100644 --- a/src/Comment.php +++ b/src/Comment.php @@ -43,6 +43,15 @@ class Comment extends Model return $this; } + + public function disapprove() + { + $this->update([ + 'is_approved' => false, + ]); + + return $this; + } protected function getAuthModelName() { @@ -57,4 +66,4 @@ class Comment extends Model throw new Exception('Could not determine the commentator model name.'); } -} \ No newline at end of file +}