diff --git a/app/controllers/oer/mymaterial.php b/app/controllers/oer/mymaterial.php index a240645c37c64fc7e05d6ba1b3d770e29711b1bc..57eace096e8ba33fe2d1918c1200c467631985c2 100644 --- a/app/controllers/oer/mymaterial.php +++ b/app/controllers/oer/mymaterial.php @@ -212,7 +212,7 @@ class Oer_MymaterialController extends AuthenticatedController _('Zugriffszahlen für %s'), $material->name )); - if (!$GLOBALS['perm']->have_perm('root') && $material->user_id && $material->user_id !== $GLOBALS['user']->id) { + if (!$GLOBALS['perm']->have_perm('root') && !$material->isMine()) { throw new AccessDeniedException(); } if (Request::get("export")) {