mirror of
https://git.code.sf.net/p/seeddms/code
synced 2026-05-08 13:31:24 +00:00
do not use controller for access control, because there is no controller
This commit is contained in:
parent
0c63537410
commit
0953c251e8
|
|
@ -27,12 +27,8 @@ include("../inc/inc.Extension.php");
|
|||
include("../inc/inc.DBInit.php");
|
||||
include("../inc/inc.Authentication.php");
|
||||
include("../inc/inc.ClassUI.php");
|
||||
include("../inc/inc.ClassController.php");
|
||||
|
||||
$tmp = explode('.', basename($_SERVER['SCRIPT_FILENAME']));
|
||||
$controller = Controller::factory($tmp[1], array('dms'=>$dms, 'user'=>$user));
|
||||
$accessop = new SeedDMS_AccessOperation($dms, null, $user, $settings);
|
||||
if (!$accessop->check_controller_access($controller, $_GET)) {
|
||||
if (!$user->isAdmin()) {
|
||||
header('Content-Type: application/json');
|
||||
echo json_encode(array('success'=>false, 'message'=>getMLText('access_denied')));
|
||||
exit;
|
||||
|
|
|
|||
Loading…
Reference in New Issue
Block a user