From 9765ec3d68e79b3eccf41905f745be74825757a6 Mon Sep 17 00:00:00 2001 From: Daniel Supernault Date: Mon, 14 Jan 2019 22:34:50 -0700 Subject: [PATCH] Update Status Model --- app/Status.php | 16 ++++++++++++++++ 1 file changed, 16 insertions(+) diff --git a/app/Status.php b/app/Status.php index 6bb363471..466ed410f 100644 --- a/app/Status.php +++ b/app/Status.php @@ -274,6 +274,22 @@ class Status extends Model __('notification.commented'); } + public function shareToText() + { + $actorName = $this->profile->username; + + return "{$actorName} ".__('notification.shared'); + } + + public function shareToHtml() + { + $actorName = $this->profile->username; + $actorUrl = $this->profile->url(); + + return "{$actorName} ". + __('notification.shared'); + } + public function recentComments() { return $this->comments()->orderBy('created_at', 'desc')->take(3);