Some refactoring of access checks - in progress.
[timetracker.git] / locking.php
index 8a6f430..2b49b83 100644 (file)
@@ -30,11 +30,15 @@ require_once('initialize.php');
 import('form.Form');
 import('ttTeamHelper');
 
-// Access check.
-if (!ttAccessAllowed('manage_advanced_settings') || !$user->isPluginEnabled('lk')) {
+// Access checks.
+if (!ttAccessAllowed('manage_advanced_settings')) {
   header('Location: access_denied.php');
   exit();
 }
+if (!$user->isPluginEnabled('lk')) {
+  header('Location: feature_disabled.php');
+  exit();
+}
 
 $cl_lock_spec = $request->isPost() ? $request->getParameter('lock_spec') : $user->lock_spec;