1
0
Fork 0
pixelfed/app/Services/StatusMentionService.php

24 lines
410 B
PHP
Raw Normal View History

2021-12-04 03:47:00 +00:00
<?php
namespace App\Services;
use Illuminate\Support\Facades\Cache;
use App\Mention;
use Illuminate\Support\Str;
class StatusMentionService
{
public static function get($id)
{
return Mention::whereStatusId($id)
->get()
->map(function($mention) {
return AccountService::get($mention->profile_id);
})->filter(function($mention) {
return $mention;
})
->values()
->toArray();
}
}