mirror of
https://github.com/pixelfed/pixelfed.git
synced 2024-11-10 00:34:50 +00:00
Lint
This commit is contained in:
parent
a75b89b239
commit
25d41901ec
1 changed files with 8 additions and 8 deletions
|
@ -41,8 +41,7 @@ class StatusController extends Controller
|
||||||
! $status ||
|
! $status ||
|
||||||
! isset($status['account'], $status['account']['username']) ||
|
! isset($status['account'], $status['account']['username']) ||
|
||||||
$status['account']['username'] != $username ||
|
$status['account']['username'] != $username ||
|
||||||
isset($status['reblog'])
|
isset($status['reblog']), 404);
|
||||||
, 404);
|
|
||||||
|
|
||||||
abort_if($status['visibility'] != 'public' && ! $request->user(), 403, 'Invalid permission');
|
abort_if($status['visibility'] != 'public' && ! $request->user(), 403, 'Invalid permission');
|
||||||
|
|
||||||
|
@ -350,6 +349,7 @@ class StatusController extends Controller
|
||||||
public function showActivityPub(Request $request, $status)
|
public function showActivityPub(Request $request, $status)
|
||||||
{
|
{
|
||||||
$key = 'pf:status:ap:v1:sid:'.$status['id'];
|
$key = 'pf:status:ap:v1:sid:'.$status['id'];
|
||||||
|
|
||||||
return Cache::remember($key, 3600, function () use ($status) {
|
return Cache::remember($key, 3600, function () use ($status) {
|
||||||
$status = Status::findOrFail($status['id']);
|
$status = Status::findOrFail($status['id']);
|
||||||
$object = $status->type == 'poll' ? new Question() : new Note();
|
$object = $status->type == 'poll' ? new Question() : new Note();
|
||||||
|
|
Loading…
Reference in a new issue