Problem/Motivation
Facing the following
The website encountered an unexpected error. Please try again later.
TypeError: array_filter(): Argument #1 ($array) must be of type array, null given in array_filter() (line 80 of modules/contrib/cl_block/src/Form/SettingsForm.php).
Drupal\cl_block\Form\SettingsForm->submitForm()
call_user_func_array() (Line: 114)
Drupal\Core\Form\FormSubmitter->executeSubmitHandlers() (Line: 52)
Drupal\Core\Form\FormSubmitter->doSubmitForm() (Line: 597)
Drupal\Core\Form\FormBuilder->processForm() (Line: 325)
Drupal\Core\Form\FormBuilder->buildForm() (Line: 73)
Drupal\Core\Controller\FormController->getContentResult()
call_user_func_array() (Line: 123)
Drupal\Core\EventSubscriber\EarlyRenderingControllerWrapperSubscriber->Drupal\Core\EventSubscriber\{closure}() (Line: 583)
Drupal\Core\Render\Renderer->executeInRenderContext() (Line: 124)
Drupal\Core\EventSubscriber\EarlyRenderingControllerWrapperSubscriber->wrapControllerExecutionInRenderContext() (Line: 97)
Drupal\Core\EventSubscriber\EarlyRenderingControllerWrapperSubscriber->Drupal\Core\EventSubscriber\{closure}() (Line: 166)
Symfony\Component\HttpKernel\HttpKernel->handleRaw() (Line: 74)
Symfony\Component\HttpKernel\HttpKernel->handle() (Line: 54)
Drupal\simple_oauth\HttpMiddleware\BasicAuthSwap->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: 48)
Drupal\Core\StackMiddleware\ReverseProxyMiddleware->handle() (Line: 51)
Drupal\Core\StackMiddleware\NegotiationMiddleware->handle() (Line: 51)
Drupal\Core\StackMiddleware\StackedHttpKernel->handle() (Line: 704)
Drupal\Core\DrupalKernel->handle() (Line: 19)
Steps to reproduce
Given that the Component Libraries: Blocks module was installed
And the system has number of SDC components
When navigating to"/admin/config/user-interface/cl-components/block"
Then the list of"Refine selection"for"Forbidden components"and "Allowed components" will show up
And the scan system will trigger to have them listed
When I press the"Save configuration"submit button
Then the following fatal error shows upTypeError: array_filter(): Argument #1 ($array) must be of type array, null given in array_filter() (line 80 of modules/contrib/cl_block/src/Form/SettingsForm.php).
Proposed resolution
- Have a basic empty array values for complex filters
- Check if the field values are arrays
Remaining tasks
- File an issue
- Patch/MR
- Test
- Review
- Release
User interface changes
- N/A
API changes
- N/A
Data model changes
- N/A
| Comment | File | Size | Author |
|---|---|---|---|
| #3 | 3365591-3.patch | 2.18 KB | rajab natshah |
Issue fork cl_block-3365591
Show commands
Start within a Git clone of the project using the version control instructions.
Or, if you do not have SSH keys set up on git.drupalcode.org:
Comments
Comment #2
rajab natshahComment #3
rajab natshahComment #5
rajab natshahComment #6
rajab natshahComment #7
rajab natshah