X-Git-Url: http://wagnertech.de/gitweb/gitweb.cgi/timetracker.git/blobdiff_plain/a8a191541d6f05b08bd8331bdf409af5abfac896..0b4060bf33c9316f79a07f870c5b1584b785e6dd:/cf_dropdown_option_add.php diff --git a/cf_dropdown_option_add.php b/cf_dropdown_option_add.php index 7b49424e..de598186 100644 --- a/cf_dropdown_option_add.php +++ b/cf_dropdown_option_add.php @@ -39,11 +39,13 @@ if (!$user->isPluginEnabled('cf')) { header('Location: feature_disabled.php'); exit(); } - -$cl_field_id = $request->getParameter('field_id'); +$cl_field_id = (int)$request->getParameter('field_id'); $field = CustomFields::getField($cl_field_id); -if (false === $field) - $err->add($i18n->get('error.db')); +if (!$field) { + header('Location: access_denied.php'); + exit(); +} +// End of access checks. $form = new Form('optionAddForm'); if ($err->no()) {