Browse Source

fix sensitive access condition and disable on direct request #37

main 2.5.1
ghost 1 year ago
parent
commit
77616c3c8a
  1. 5
      src/Controller/TorrentController.php

5
src/Controller/TorrentController.php

@ -57,10 +57,13 @@ class TorrentController extends AbstractController @@ -57,10 +57,13 @@ class TorrentController extends AbstractController
}
// Sensitive filter
if (!$user->isModerator() && $user->isSensitive())
// @TODO add blur effect or sensitive notice instead of 404 on direct request #37
/*
if (!$user->isModerator() && $user->isSensitive() && $torrent->isSensitive())
{
throw $this->createNotFoundException();
}
*/
// Access filter
if (!$user->isModerator() && $user->getId() != $torrent->getUserId() &&

Loading…
Cancel
Save