- Issue created by @loze
- Merge request !3issue #3409377 fixed invalid call to $account->ui() to $account->id() β (Open) created by loze
- Status changed to Needs review
about 1 year ago 6:18am 18 December 2023
Once in a while I see these in watchdog
Message Error: Call to undefined method Drupal\Core\Session\AccountProxy::ui() in Drupal\timezone_detect\Controller\SetTimezoneController->updateTimezone() (line 88 of /var/www/vhosts/..../web/modules/contrib/timezone_detect/src/Controller/SetTimezoneController.php)
#0 [internal function]: Drupal\timezone_detect\Controller\SetTimezoneController->updateTimezone()
#1 /var/www/vhosts/..../web/core/lib/Drupal/Core/EventSubscriber/EarlyRenderingControllerWrapperSubscriber.php(123): call_user_func_array()
#2 /var/www/vhosts/..../web/core/lib/Drupal/Core/Render/Renderer.php(580): Drupal\Core\EventSubscriber\EarlyRenderingControllerWrapperSubscriber->Drupal\Core\EventSubscriber\{closure}()
#3 /var/www/vhosts/..../web/core/lib/Drupal/Core/EventSubscriber/EarlyRenderingControllerWrapperSubscriber.php(124): Drupal\Core\Render\Renderer->executeInRenderContext()
The code in the error logger should be to $account->id() not $account->ui()
Will provide a patch
Needs review
1.0
Code