You are here

public function MailchimpCampaignDeleteForm::afterBuild in Mailchimp 8

Same name and namespace in other branches
  1. 2.x modules/mailchimp_campaign/src/Form/MailchimpCampaignDeleteForm.php \Drupal\mailchimp_campaign\Form\MailchimpCampaignDeleteForm::afterBuild()

// TODO: Make sure override afterBuild is the correct solution.

Have to disable EntityForm::afterbuild for this form. Drupal was attempting to get a field definition for the submit button from the MailchimpCampaign entity, which doesn't (and shouldn't) have it.

Overrides EntityForm::afterBuild

File

modules/mailchimp_campaign/src/Form/MailchimpCampaignDeleteForm.php, line 93

Class

MailchimpCampaignDeleteForm
Form controller for the MailchimpCampaign entity delete form.

Namespace

Drupal\mailchimp_campaign\Form

Code

public function afterBuild(array $element, FormStateInterface $form_state) {
  return $element;
}