You are here

private function ContactFormBlock::getContactForm in Form Block 8

Same name and namespace in other branches
  1. 2.0.x src/Plugin/Block/ContactFormBlock.php \Drupal\formblock\Plugin\Block\ContactFormBlock::getContactForm()

Return the contact form entity (type of contact form).

Return value

\Drupal\contact\Entity\ContactForm The contact form type.

File

src/Plugin/Block/ContactFormBlock.php, line 237

Class

ContactFormBlock
Provides a block for contact form.

Namespace

Drupal\formblock\Plugin\Block

Code

private function getContactForm() {
  return $this->entityTypeManager
    ->getStorage('contact_form')
    ->load($this->configuration['contact_form']);
}