X-Git-Url: https://vcs.fsf.org/?a=blobdiff_plain;f=CRM%2FContribute%2FForm%2FContributionPage.php;h=ba8bb64ec08706d24b8822fe9dc816d4af568f4b;hb=fe71a72e510e046d7f21d7064802a15f64c6b957;hp=95132b675c3bea978efbf06a2e1145c60bfe08ff;hpb=1ba43e8d0d271e4c3b4d84fb7f519c55329981ab;p=civicrm-core.git diff --git a/CRM/Contribute/Form/ContributionPage.php b/CRM/Contribute/Form/ContributionPage.php index 95132b675c..ba8bb64ec0 100644 --- a/CRM/Contribute/Form/ContributionPage.php +++ b/CRM/Contribute/Form/ContributionPage.php @@ -136,7 +136,7 @@ class CRM_Contribute_Form_ContributionPage extends CRM_Core_Form { if (CRM_Financial_BAO_FinancialType::isACLFinancialTypeStatus() && $this->_action & CRM_Core_Action::UPDATE) { $financialTypeID = CRM_Contribute_PseudoConstant::financialType($this->_values['financial_type_id']); if (!CRM_Core_Permission::check('edit contributions of type ' . $financialTypeID)) { - CRM_Core_Error::fatal(ts('You do not have permission to access this page.')); + CRM_Core_Error::statusBounce(ts('You do not have permission to access this page.')); } } @@ -156,7 +156,7 @@ class CRM_Contribute_Form_ContributionPage extends CRM_Core_Form { $this->applyFilter('__ALL__', 'trim'); $session = CRM_Core_Session::singleton(); - $this->_cancelURL = CRM_Utils_Array::value('cancelURL', $_POST); + $this->_cancelURL = $_POST['cancelURL'] ?? NULL; if (!$this->_cancelURL) { $this->_cancelURL = CRM_Utils_System::url('civicrm/admin/contribute', 'reset=1'); @@ -289,7 +289,7 @@ class CRM_Contribute_Form_ContributionPage extends CRM_Core_Form { 'is_pledge_start_date_editable', ]; foreach ($pledgeBlock as $key) { - $defaults[$key] = CRM_Utils_Array::value($key, $pledgeBlockDefaults); + $defaults[$key] = $pledgeBlockDefaults[$key] ?? NULL; if ($key == 'pledge_start_date' && !empty($pledgeBlockDefaults[$key])) { $defaultPledgeDate = (array) json_decode($pledgeBlockDefaults['pledge_start_date']); $pledgeDateFields = [