Merge pull request #6 from nickbyte/master

Adding method for disapproving a comment
This commit is contained in:
Marcel Pociot
2019-02-28 14:27:11 +01:00
committed by GitHub
+9
View File
@@ -44,6 +44,15 @@ class Comment extends Model
return $this; return $this;
} }
public function disapprove()
{
$this->update([
'is_approved' => false,
]);
return $this;
}
protected function getAuthModelName() protected function getAuthModelName()
{ {
if (config('comments.user_model')) { if (config('comments.user_model')) {