forked from mirror/pixelfed
Update LikeController, store status_profile_id and is_comment attributes
This commit is contained in:
parent
7d0f7f7222
commit
799a4cba12
1 changed files with 9 additions and 0 deletions
|
@ -43,6 +43,15 @@ class LikeController extends Controller
|
|||
if($like->wasRecentlyCreated == true) {
|
||||
$count++;
|
||||
$status->likes_count = $count;
|
||||
$like->status_profile_id = $status->profile_id;
|
||||
$like->is_comment = in_array($status->type, [
|
||||
'photo',
|
||||
'photo:album',
|
||||
'video',
|
||||
'video:album',
|
||||
'photo:video:album'
|
||||
]) == false;
|
||||
$like->save();
|
||||
$status->save();
|
||||
LikePipeline::dispatch($like);
|
||||
}
|
||||
|
|
Loading…
Reference in a new issue