Update StatusController, fix unlisted post guest/ap access bug

This commit is contained in:
Daniel Supernault 2024-06-21 04:03:11 -06:00
parent 3437d9bb48
commit 83098428bb
No known key found for this signature in database
GPG key ID: 23740873EE6F76A1

View file

@ -43,7 +43,7 @@ class StatusController extends Controller
$status['account']['username'] != $username ||
isset($status['reblog']), 404);
abort_if($status['visibility'] != 'public' && ! $request->user(), 403, 'Invalid permission');
abort_if(! in_array($status['visibility'], ['public', 'unlisted']) && ! $request->user(), 403, 'Invalid permission');
if ($request->wantsJson() && (bool) config_cache('federation.activitypub.enabled')) {
return $this->showActivityPub($request, $status);