diff --git a/modules/examiner/php/addexaminer.class.inc b/modules/examiner/php/addexaminer.class.inc index 55edb751dde..23cd7e2a545 100644 --- a/modules/examiner/php/addexaminer.class.inc +++ b/modules/examiner/php/addexaminer.class.inc @@ -66,15 +66,10 @@ class AddExaminer extends \NDB_Page // check for site permissions $user = \User::singleton(); - if (!$user->hasAnyPermission( - [ - 'superuser', - 'examiner_multisite', - ] - ) + if (!$user->hasAnyPermission('examiner_multisite') && !in_array($siteID, $user->getCenterIDs()) ) { - return new \LORIS\Http\Response\JSON\Conflict( + return new \LORIS\Http\Response\JSON\Forbidden( 'Permission denied: You cannot assign examiner to this Site.' ); };