You are here

public function PaymentMethodAddForm::getErrorElement in Commerce Core 8.2

Gets the form element to which errors should be assigned.

Parameters

array $form: The form, as built by buildConfigurationForm().

\Drupal\Core\Form\FormStateInterface $form_state: The current state of the form.

Return value

array The form element.

Overrides PaymentGatewayFormBase::getErrorElement

File

modules/payment/src/PluginForm/PaymentMethodAddForm.php, line 15

Class

PaymentMethodAddForm

Namespace

Drupal\commerce_payment\PluginForm

Code

public function getErrorElement(array $form, FormStateInterface $form_state) {
  return $form['payment_details'];
}