// contribution amount to be null, so that it will not show
// contribution amount same as membership amount.
if ($this->_membershipBlock['is_separate_payment']
- && $this->_values['fee'][$priceField->id]['name'] == 'contribution_amount'
- && $this->_params["price_{$priceField->id}"] == '-1'
+ && CRM_Utils_Array::value('name', $this->_values['fee'][$priceField->id]) == 'contribution_amount'
+ && CRM_Utils_Array::value("price_{$priceField->id}", $this->_params) == '-1'
) {
$this->_params['amount'] = null;
}