call to undefined method formbuilder in drupal v10.3.1

Created on 11 July 2024, 5 months ago
Updated 16 July 2024, 5 months ago

Drupal Version: 10.3.1, PHP version 8.3.9

Domain version: 2.0.0-beta1

Expected Behavior

url: /admin/config/domain
should produce a form showing existing domain records and allow changes

Actual Behavior

The website encountered an unexpected error. Try again later.
Error: Call to undefined method Drupal\domain\DomainListBuilder::formBuilder() in Drupal\domain\DomainListBuilder->render() (line 318 of modules/contrib/domain/domain/src/DomainListBuilder.php).

Steps to reproduce

  • To reproduce, upgrade drupal and navigate to /admin/config/domain
  • This error never happened before the drupal upgrade from drupal version 10.2.7 to version 10.3.1, always happens afterwards

My workaround

  • change the line from:
  • $form = $this->formBuilder()->getForm($this);
  • to :
  • $form = \Drupal::formBuilder()->getForm($this);
๐Ÿ› Bug report
Status

Closed: duplicate

Version

2.0

Component

- Domain Config UI

Created by

๐Ÿ‡ณ๐Ÿ‡ฟNew Zealand Cadencia

Live updates comments and jobs are added and updated live.
Sign in to follow issues

Merge Requests

Comments & Activities

Production build 0.71.5 2024