1
0
Fork 0

Merge pull request #353 from pixelfed/frontend-ui-refactor

Update Status model
This commit is contained in:
daniel 2018-08-10 01:06:46 -06:00 committed by GitHub
commit 9dba310f2f
No known key found for this signature in database
GPG Key ID: 4AEE18F83AFDEB23
1 changed files with 3 additions and 0 deletions

View File

@ -92,6 +92,9 @@ class Status extends Model
public function bookmarked()
{
if(!Auth::check()) {
return 0;
}
$profile = Auth::user()->profile;
return Bookmark::whereProfileId($profile->id)->whereStatusId($this->id)->count();
}