From 853d4fd5340e3b47b76539bf9d11314bfc1aca58 Mon Sep 17 00:00:00 2001 From: Eric Lippmann Date: Thu, 27 Aug 2015 13:44:49 +0200 Subject: [PATCH] Use UrlParams::getRequired() in RoleController::editAction() --- application/controllers/RoleController.php | 8 +------- 1 file changed, 1 insertion(+), 7 deletions(-) diff --git a/application/controllers/RoleController.php b/application/controllers/RoleController.php index 795630280..809bc59a3 100644 --- a/application/controllers/RoleController.php +++ b/application/controllers/RoleController.php @@ -69,13 +69,7 @@ class RoleController extends AuthBackendController public function editAction() { $this->assertPermission('config/authentication/roles/edit'); - $name = $this->_request->getParam('role'); - if (empty($name)) { - throw new Zend_Controller_Action_Exception( - sprintf($this->translate('Required parameter \'%s\' missing'), 'role'), - 400 - ); - } + $name = $this->params->getRequired('role'); $role = new RoleForm(); $role->setTitle(sprintf($this->translate('Update Role %s'), $name)); $role->setSubmitLabel($this->translate('Update Role'));