Illegal offset type in isset or empty ContainerAwareEventDispatcher.php

Created on 13 August 2021, over 3 years ago
Updated 4 March 2024, 9 months ago

Problem/Motivation

Recent fixes to WebhookController.php don't seem to be OK

Referrer - http://test.javakitchen.eu/mollie/redirect/mollie_commerce/[ID]

Trace logs

#1

Warning: Illegal offset type in isset or empty in Drupal\Component\EventDispatcher\ContainerAwareEventDispatcher->dispatch() (line 94 of /data/vhosts/wwwroot/html/java-kitchen-prod/web/core/lib/Drupal/Component/EventDispatcher/ContainerAwareEventDispatcher.php)
#0 /data/vhosts/wwwroot/html/java-kitchen-prod/web/core/includes/bootstrap.inc(600): _drupal_error_handler_real()
#1 /data/vhosts/wwwroot/html/java-kitchen-prod/web/core/lib/Drupal/Component/EventDispatcher/ContainerAwareEventDispatcher.php(94): _drupal_error_handler()
#2 /data/vhosts/wwwroot/html/java-kitchen-prod/web/modules/contrib/mollie/src/Controller/RedirectController.php(65): Drupal\Component\EventDispatcher\ContainerAwareEventDispatcher->dispatch()
#3 [internal function]: Drupal\mollie\Controller\RedirectController->paymentRedirect()
#4 /data/vhosts/wwwroot/html/java-kitchen-prod/web/core/lib/Drupal/Core/EventSubscriber/EarlyRenderingControllerWrapperSubscriber.php(123): call_user_func_array()
#5 /data/vhosts/wwwroot/html/java-kitchen-prod/web/core/lib/Drupal/Core/Render/Renderer.php(573): Drupal\Core\EventSubscriber\EarlyRenderingControllerWrapperSubscriber->Drupal\Core\EventSubscriber\{closure}()
#6 /data/vhosts/wwwroot/html/java-kitchen-prod/web/core/lib/Drupal/Core/EventSubscriber/EarlyRenderingControllerWrapperSubscriber.php(124): Drupal\Core\Render\Renderer->executeInRenderContext()
#7 /data/vhosts/wwwroot/html/java-kitchen-prod/web/core/lib/Drupal/Core/EventSubscriber/EarlyRenderingControllerWrapperSubscriber.php(97): Drupal\Core\EventSubscriber\EarlyRenderingControllerWrapperSubscriber->wrapControllerExecutionInRenderContext()
#8 /data/vhosts/wwwroot/html/java-kitchen-prod/vendor/symfony/http-kernel/HttpKernel.php(151): Drupal\Core\EventSubscriber\EarlyRenderingControllerWrapperSubscriber->Drupal\Core\EventSubscriber\{closure}()
#9 /data/vhosts/wwwroot/html/java-kitchen-prod/vendor/symfony/http-kernel/HttpKernel.php(68): Symfony\Component\HttpKernel\HttpKernel->handleRaw()
#10 /data/vhosts/wwwroot/html/java-kitchen-prod/web/core/lib/Drupal/Core/StackMiddleware/Session.php(57): Symfony\Component\HttpKernel\HttpKernel->handle()
#11 /data/vhosts/wwwroot/html/java-kitchen-prod/web/core/lib/Drupal/Core/StackMiddleware/KernelPreHandle.php(47): Drupal\Core\StackMiddleware\Session->handle()
#12 /data/vhosts/wwwroot/html/java-kitchen-prod/web/core/modules/page_cache/src/StackMiddleware/PageCache.php(106): Drupal\Core\StackMiddleware\KernelPreHandle->handle()
#13 /data/vhosts/wwwroot/html/java-kitchen-prod/web/core/modules/page_cache/src/StackMiddleware/PageCache.php(85): Drupal\page_cache\StackMiddleware\PageCache->pass()
#14 /data/vhosts/wwwroot/html/java-kitchen-prod/web/modules/contrib/advban/src/AdvbanMiddleware.php(57): Drupal\page_cache\StackMiddleware\PageCache->handle()
#15 /data/vhosts/wwwroot/html/java-kitchen-prod/web/core/modules/ban/src/BanMiddleware.php(50): Drupal\advban\AdvbanMiddleware->handle()
#16 /data/vhosts/wwwroot/html/java-kitchen-prod/web/core/lib/Drupal/Core/StackMiddleware/ReverseProxyMiddleware.php(47): Drupal\ban\BanMiddleware->handle()
#17 /data/vhosts/wwwroot/html/java-kitchen-prod/web/core/lib/Drupal/Core/StackMiddleware/NegotiationMiddleware.php(52): Drupal\Core\StackMiddleware\ReverseProxyMiddleware->handle()
#18 /data/vhosts/wwwroot/html/java-kitchen-prod/vendor/stack/builder/src/Stack/StackedHttpKernel.php(23): Drupal\Core\StackMiddleware\NegotiationMiddleware->handle()
#19 /data/vhosts/wwwroot/html/java-kitchen-prod/web/core/lib/Drupal/Core/DrupalKernel.php(708): Stack\StackedHttpKernel->handle()
#20 /data/vhosts/wwwroot/html/java-kitchen-prod/web/index.php(19): Drupal\Core\DrupalKernel->handle()
#21 {main}

#2

Error: Call to a member function get() on null in Drupal\mollie\Controller\WebhookController->invokeStatusChangeHook() (line 118 of /data/vhosts/wwwroot/html/java-kitchen-prod/web/modules/contrib/mollie/src/Controller/WebhookController.php)
#0 [internal function]: Drupal\mollie\Controller\WebhookController->invokeStatusChangeHook()
#1 /data/vhosts/wwwroot/html/java-kitchen-prod/web/core/lib/Drupal/Core/EventSubscriber/EarlyRenderingControllerWrapperSubscriber.php(123): call_user_func_array()
#2 /data/vhosts/wwwroot/html/java-kitchen-prod/web/core/lib/Drupal/Core/Render/Renderer.php(573): Drupal\Core\EventSubscriber\EarlyRenderingControllerWrapperSubscriber->Drupal\Core\EventSubscriber\{closure}()
#3 /data/vhosts/wwwroot/html/java-kitchen-prod/web/core/lib/Drupal/Core/EventSubscriber/EarlyRenderingControllerWrapperSubscriber.php(124): Drupal\Core\Render\Renderer->executeInRenderContext()
#4 /data/vhosts/wwwroot/html/java-kitchen-prod/web/core/lib/Drupal/Core/EventSubscriber/EarlyRenderingControllerWrapperSubscriber.php(97): Drupal\Core\EventSubscriber\EarlyRenderingControllerWrapperSubscriber->wrapControllerExecutionInRenderContext()
#5 /data/vhosts/wwwroot/html/java-kitchen-prod/vendor/symfony/http-kernel/HttpKernel.php(151): Drupal\Core\EventSubscriber\EarlyRenderingControllerWrapperSubscriber->Drupal\Core\EventSubscriber\{closure}()
#6 /data/vhosts/wwwroot/html/java-kitchen-prod/vendor/symfony/http-kernel/HttpKernel.php(68): Symfony\Component\HttpKernel\HttpKernel->handleRaw()
#7 /data/vhosts/wwwroot/html/java-kitchen-prod/web/core/lib/Drupal/Core/StackMiddleware/Session.php(57): Symfony\Component\HttpKernel\HttpKernel->handle()
#8 /data/vhosts/wwwroot/html/java-kitchen-prod/web/core/lib/Drupal/Core/StackMiddleware/KernelPreHandle.php(47): Drupal\Core\StackMiddleware\Session->handle()
#9 /data/vhosts/wwwroot/html/java-kitchen-prod/web/core/modules/page_cache/src/StackMiddleware/PageCache.php(106): Drupal\Core\StackMiddleware\KernelPreHandle->handle()
#10 /data/vhosts/wwwroot/html/java-kitchen-prod/web/core/modules/page_cache/src/StackMiddleware/PageCache.php(85): Drupal\page_cache\StackMiddleware\PageCache->pass()
#11 /data/vhosts/wwwroot/html/java-kitchen-prod/web/modules/contrib/advban/src/AdvbanMiddleware.php(57): Drupal\page_cache\StackMiddleware\PageCache->handle()
#12 /data/vhosts/wwwroot/html/java-kitchen-prod/web/core/modules/ban/src/BanMiddleware.php(50): Drupal\advban\AdvbanMiddleware->handle()
#13 /data/vhosts/wwwroot/html/java-kitchen-prod/web/core/lib/Drupal/Core/StackMiddleware/ReverseProxyMiddleware.php(47): Drupal\ban\BanMiddleware->handle()
#14 /data/vhosts/wwwroot/html/java-kitchen-prod/web/core/lib/Drupal/Core/StackMiddleware/NegotiationMiddleware.php(52): Drupal\Core\StackMiddleware\ReverseProxyMiddleware->handle()
#15 /data/vhosts/wwwroot/html/java-kitchen-prod/vendor/stack/builder/src/Stack/StackedHttpKernel.php(23): Drupal\Core\StackMiddleware\NegotiationMiddleware->handle()
#16 /data/vhosts/wwwroot/html/java-kitchen-prod/web/core/lib/Drupal/Core/DrupalKernel.php(708): Stack\StackedHttpKernel->handle()
#17 /data/vhosts/wwwroot/html/java-kitchen-prod/web/index.php(19): Drupal\Core\DrupalKernel->handle()
#18 {main}

#3

Warning: Illegal offset type in isset or empty in Drupal\Component\EventDispatcher\ContainerAwareEventDispatcher->dispatch() (line 94 of /data/vhosts/wwwroot/html/java-kitchen-prod/web/core/lib/Drupal/Component/EventDispatcher/ContainerAwareEventDispatcher.php)
#0 /data/vhosts/wwwroot/html/java-kitchen-prod/web/core/includes/bootstrap.inc(600): _drupal_error_handler_real()
#1 /data/vhosts/wwwroot/html/java-kitchen-prod/web/core/lib/Drupal/Component/EventDispatcher/ContainerAwareEventDispatcher.php(94): _drupal_error_handler()
#2 /data/vhosts/wwwroot/html/java-kitchen-prod/web/modules/contrib/mollie/src/Controller/RedirectController.php(65): Drupal\Component\EventDispatcher\ContainerAwareEventDispatcher->dispatch()
#3 [internal function]: Drupal\mollie\Controller\RedirectController->paymentRedirect()
#4 /data/vhosts/wwwroot/html/java-kitchen-prod/web/core/lib/Drupal/Core/EventSubscriber/EarlyRenderingControllerWrapperSubscriber.php(123): call_user_func_array()
#5 /data/vhosts/wwwroot/html/java-kitchen-prod/web/core/lib/Drupal/Core/Render/Renderer.php(573): Drupal\Core\EventSubscriber\EarlyRenderingControllerWrapperSubscriber->Drupal\Core\EventSubscriber\{closure}()
#6 /data/vhosts/wwwroot/html/java-kitchen-prod/web/core/lib/Drupal/Core/EventSubscriber/EarlyRenderingControllerWrapperSubscriber.php(124): Drupal\Core\Render\Renderer->executeInRenderContext()
#7 /data/vhosts/wwwroot/html/java-kitchen-prod/web/core/lib/Drupal/Core/EventSubscriber/EarlyRenderingControllerWrapperSubscriber.php(97): Drupal\Core\EventSubscriber\EarlyRenderingControllerWrapperSubscriber->wrapControllerExecutionInRenderContext()
#8 /data/vhosts/wwwroot/html/java-kitchen-prod/vendor/symfony/http-kernel/HttpKernel.php(151): Drupal\Core\EventSubscriber\EarlyRenderingControllerWrapperSubscriber->Drupal\Core\EventSubscriber\{closure}()
#9 /data/vhosts/wwwroot/html/java-kitchen-prod/vendor/symfony/http-kernel/HttpKernel.php(68): Symfony\Component\HttpKernel\HttpKernel->handleRaw()
#10 /data/vhosts/wwwroot/html/java-kitchen-prod/web/core/lib/Drupal/Core/StackMiddleware/Session.php(57): Symfony\Component\HttpKernel\HttpKernel->handle()
#11 /data/vhosts/wwwroot/html/java-kitchen-prod/web/core/lib/Drupal/Core/StackMiddleware/KernelPreHandle.php(47): Drupal\Core\StackMiddleware\Session->handle()
#12 /data/vhosts/wwwroot/html/java-kitchen-prod/web/core/modules/page_cache/src/StackMiddleware/PageCache.php(106): Drupal\Core\StackMiddleware\KernelPreHandle->handle()
#13 /data/vhosts/wwwroot/html/java-kitchen-prod/web/core/modules/page_cache/src/StackMiddleware/PageCache.php(85): Drupal\page_cache\StackMiddleware\PageCache->pass()
#14 /data/vhosts/wwwroot/html/java-kitchen-prod/web/modules/contrib/advban/src/AdvbanMiddleware.php(57): Drupal\page_cache\StackMiddleware\PageCache->handle()
#15 /data/vhosts/wwwroot/html/java-kitchen-prod/web/core/modules/ban/src/BanMiddleware.php(50): Drupal\advban\AdvbanMiddleware->handle()
#16 /data/vhosts/wwwroot/html/java-kitchen-prod/web/core/lib/Drupal/Core/StackMiddleware/ReverseProxyMiddleware.php(47): Drupal\ban\BanMiddleware->handle()
#17 /data/vhosts/wwwroot/html/java-kitchen-prod/web/core/lib/Drupal/Core/StackMiddleware/NegotiationMiddleware.php(52): Drupal\Core\StackMiddleware\ReverseProxyMiddleware->handle()
#18 /data/vhosts/wwwroot/html/java-kitchen-prod/vendor/stack/builder/src/Stack/StackedHttpKernel.php(23): Drupal\Core\StackMiddleware\NegotiationMiddleware->handle()
#19 /data/vhosts/wwwroot/html/java-kitchen-prod/web/core/lib/Drupal/Core/DrupalKernel.php(708): Stack\StackedHttpKernel->handle()
#20 /data/vhosts/wwwroot/html/java-kitchen-prod/web/index.php(19): Drupal\Core\DrupalKernel->handle()
#21 {main}

Steps to reproduce

Create order, pay with mollie, 1) lands on admin payments section (unauthenticated non-admin user gets a 404 or access denied), so order still in cart

Drupal version : 8.9.18
WS : Apache/2.4.41 (Ubuntu)
PHP v. 7.4.3
dB / 8.0.22-13 - System MySQL, MariaDB, Percona Server, or equivalent

🐛 Bug report
Status

Fixed

Version

2.1

Component

Code

Created by

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

Comments & Activities

Not all content is available!

It's likely this issue predates Contrib.social: some issue and comment data are missing.

Production build 0.71.5 2024