Skip to content

Commit

Permalink
Fix download permission issue
Browse files Browse the repository at this point in the history
  • Loading branch information
Xinecraft committed Dec 25, 2023
1 parent 66e5c27 commit 7ede827
Showing 1 changed file with 1 addition and 1 deletion.
2 changes: 1 addition & 1 deletion app/Policies/DownloadPolicy.php
Original file line number Diff line number Diff line change
Expand Up @@ -48,7 +48,7 @@ public function delete(User $user, Download $download)
public function download(?User $user, Download $download)
{
// If admin, true
if ($user->can('read downloads')) {
if ($user?->can('read downloads')) {
return true;
}

Expand Down

0 comments on commit 7ede827

Please sign in to comment.