- Issue created by @coaston
- Status changed to Fixed
9 months ago 6:07pm 28 March 2024 - Status changed to Fixed
9 months ago 6:33pm 4 April 2024
Warning: foreach() argument must be of type array|object, null given in Drupal\custom_field\Plugin\Field\FieldFormatter\BaseFormatter->calculateDependencies() (line 391 of modules\contrib\custom_field\src\Plugin\Field\FieldFormatter\BaseFormatter.php).
Drupal\custom_field\Plugin\Field\FieldFormatter\BaseFormatter->calculateDependencies() (Line: 71)
Drupal\views\Plugin\views\field\EntityField->getPluginDependencies(Object) (Line: 89)
Drupal\views\Plugin\views\field\EntityField->calculatePluginDependencies(Object) (Line: 1021)
Drupal\views\Plugin\views\field\EntityField->calculateDependencies() (Line: 71)
Drupal\views\Plugin\views\display\DisplayPluginBase->getPluginDependencies(Object) (Line: 89)
Drupal\views\Plugin\views\display\DisplayPluginBase->calculatePluginDependencies(Object, 1)
array_walk(Array, Array) (Line: 959)
Drupal\views\Plugin\views\display\DisplayPluginBase->calculateDependencies() (Line: 71)
Drupal\Core\Config\Entity\ConfigEntityBase->getPluginDependencies(Object) (Line: 89)
Drupal\Core\Config\Entity\ConfigEntityBase->calculatePluginDependencies(Object) (Line: 282)
Drupal\views\Entity\View->calculateDependencies() (Line: 320)
Drupal\Core\Config\Entity\ConfigEntityBase->preSave(Object) (Line: 292)
Drupal\views\Entity\View->preSave(Object) (Line: 562)
Drupal\Core\Entity\EntityStorageBase->doPreSave(Object) (Line: 517)
Drupal\Core\Entity\EntityStorageBase->save(Object) (Line: 253)
Drupal\Core\Config\Entity\ConfigEntityStorage->save(Object) (Line: 339)
Drupal\Core\Entity\EntityBase->save() (Line: 608)
Drupal\Core\Config\Entity\ConfigEntityBase->save() (Line: 1001)
Drupal\views_ui\ViewUI->save() (Line: 337)
Drupal\views_ui\ViewEditForm->save(Array, Object)
call_user_func_array(Array, Array) (Line: 114)
Drupal\Core\Form\FormSubmitter->executeSubmitHandlers(Array, Object) (Line: 52)
Drupal\Core\Form\FormSubmitter->doSubmitForm(Array, Object) (Line: 597)
Drupal\Core\Form\FormBuilder->processForm('view_edit_form', Array, Object) (Line: 325)
Drupal\Core\Form\FormBuilder->buildForm(Object, Object) (Line: 48)
Drupal\Core\Entity\EntityFormBuilder->getForm(Object, 'edit', Array) (Line: 230)
Drupal\views_ui\Controller\ViewsUIController->edit(Object, 'block_1')
call_user_func_array(Array, Array) (Line: 123)
Drupal\Core\EventSubscriber\EarlyRenderingControllerWrapperSubscriber->Drupal\Core\EventSubscriber\{closure}() (Line: 580)
Drupal\Core\Render\Renderer->executeInRenderContext(Object, Object) (Line: 124)
Drupal\Core\EventSubscriber\EarlyRenderingControllerWrapperSubscriber->wrapControllerExecutionInRenderContext(Array, Array) (Line: 97)
Drupal\Core\EventSubscriber\EarlyRenderingControllerWrapperSubscriber->Drupal\Core\EventSubscriber\{closure}() (Line: 169)
Symfony\Component\HttpKernel\HttpKernel->handleRaw(Object, 1) (Line: 81)
Symfony\Component\HttpKernel\HttpKernel->handle(Object, 1, 1) (Line: 58)
Drupal\Core\StackMiddleware\Session->handle(Object, 1, 1) (Line: 48)
Drupal\Core\StackMiddleware\KernelPreHandle->handle(Object, 1, 1) (Line: 48)
Drupal\Core\StackMiddleware\ReverseProxyMiddleware->handle(Object, 1, 1) (Line: 51)
Drupal\Core\StackMiddleware\NegotiationMiddleware->handle(Object, 1, 1) (Line: 23)
Stack\StackedHttpKernel->handle(Object, 1, 1) (Line: 718)
Drupal\Core\DrupalKernel->handle(Object) (Line: 19)
1.Create a custom field (i have used 6 text plain (select list widgets for some of them)
2.Create content
3.Create view
4.Add custom field to view and use CUSTOM template
5.Add several fields to custom template (the same for all)
6.Save view
Fixed
3.0
Code