- Issue created by @trickfun
- Status changed to Fixed
8 months ago 1:36pm 17 April 2024 Automatically closed - issue fixed for 2 weeks with no activity.
I have this error:
in drupal 10.1 EventDispatcher::dispatch() argument order changed.
The website encountered an unexpected error. Please try again later.<br><br><em class="placeholder">TypeError</em>:
Drupal\Component\EventDispatcher\ContainerAwareEventDispatcher::dispatch(): Argument #1 ($event) must be of type object,
string given, called in /var/www/html/web/modules/contrib/rest_api_access_token/src/Controller/AuthController.php on
line 118 in <em class="placeholder">Drupal\Component\EventDispatcher\ContainerAwareEventDispatcher->dispatch()</em>
(line <em class="placeholder">89</em> of
<em class="placeholder">core/lib/Drupal/Component/EventDispatcher/ContainerAwareEventDispatcher.php</em>).
<pre class="backtrace">Drupal\rest_api_access_token\Controller\AuthController->tokenResponse(Object)
call_user_func_array(Array, Array) (Line: 123)
Drupal\Core\EventSubscriber\EarlyRenderingControllerWrapperSubscriber->Drupal\Core\EventSubscriber\{closure}() (Line: 592)
Drupal\Core\Render\Renderer->executeInRenderContext(Object, Object) (Line: 121)
Drupal\Core\EventSubscriber\EarlyRenderingControllerWrapperSubscriber->wrapControllerExecutionInRenderContext(Array, Array) (Line: 97)
Drupal\Core\EventSubscriber\EarlyRenderingControllerWrapperSubscriber->Drupal\Core\EventSubscriber\{closure}() (Line: 181)
Symfony\Component\HttpKernel\HttpKernel->handleRaw(Object, 1) (Line: 76)
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: 106)
Drupal\page_cache\StackMiddleware\PageCache->pass(Object, 1, 1) (Line: 85)
Drupal\page_cache\StackMiddleware\PageCache->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: 51)
Drupal\Core\StackMiddleware\StackedHttpKernel->handle(Object, 1, 1) (Line: 704)
Drupal\Core\DrupalKernel->handle(Object) (Line: 19)
</pre>
Login with api/v1/auth/token
Fixed
2.0
Code
Automatically closed - issue fixed for 2 weeks with no activity.