1
0
Fork 0
forked from mirror/pixelfed

Update StatusController

This commit is contained in:
Daniel Supernault 2019-05-12 22:32:33 -06:00
parent b7a7368c62
commit f033f84159
No known key found for this signature in database
GPG key ID: 0DEF1C662C9033F7

View file

@ -229,14 +229,12 @@ class StatusController extends Controller
$this->authCheck();
$this->validate($request, [
'item' => 'required|integer',
'item' => 'required|integer|min:1',
]);
$profile = Auth::user()->profile;
$status = Status::withCount('shares')->findOrFail($request->input('item'));
Cache::forget('transform:status:'.$status->url());
$count = $status->shares_count;
$exists = Status::whereProfileId(Auth::user()->profile->id)