Accessing "Name formats" throws TypeError: array_slice()

Created on 17 April 2023, over 1 year ago

When I go to access mydomain.com/admin/config/regional/name

I'm met with the following error:

TypeError: array_slice(): Argument #1 ($array) must be of type array, null given in array_slice() (line 165 of modules/contrib/name/src/NameGenerator.php).
array_slice() (Line: 165)
Drupal\name\NameGenerator->loadSampleValues() (Line: 106)
Drupal\name\NameFormatListBuilder->examples() (Line: 90)
Drupal\name\NameFormatListBuilder->buildRow() (Line: 219)
Drupal\Core\Entity\EntityListBuilder->render() (Line: 126)
Drupal\name\NameFormatListBuilder->render() (Line: 23)
Drupal\Core\Entity\Controller\EntityListController->listing()
call_user_func_array() (Line: 123)
Drupal\Core\EventSubscriber\EarlyRenderingControllerWrapperSubscriber->Drupal\Core\EventSubscriber\{closure}() (Line: 580)
Drupal\Core\Render\Renderer->executeInRenderContext() (Line: 124)
Drupal\Core\EventSubscriber\EarlyRenderingControllerWrapperSubscriber->wrapControllerExecutionInRenderContext() (Line: 97)
Drupal\Core\EventSubscriber\EarlyRenderingControllerWrapperSubscriber->Drupal\Core\EventSubscriber\{closure}() (Line: 169)
Symfony\Component\HttpKernel\HttpKernel->handleRaw() (Line: 81)
Symfony\Component\HttpKernel\HttpKernel->handle() (Line: 58)
Drupal\Core\StackMiddleware\Session->handle() (Line: 48)
Drupal\Core\StackMiddleware\KernelPreHandle->handle() (Line: 106)
Drupal\page_cache\StackMiddleware\PageCache->pass() (Line: 85)
Drupal\page_cache\StackMiddleware\PageCache->handle() (Line: 50)
Drupal\ban\BanMiddleware->handle() (Line: 48)
Drupal\Core\StackMiddleware\ReverseProxyMiddleware->handle() (Line: 51)
Drupal\Core\StackMiddleware\NegotiationMiddleware->handle() (Line: 23)
Stack\StackedHttpKernel->handle() (Line: 718)
Drupal\Core\DrupalKernel->handle() (Line: 19)

This is on Drupal 9.5. This was also true for 1.0.0-rc4

🐛 Bug report
Status

Active

Component

User interface

Created by

🇺🇸United States mrogers78

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