Skip to content

Internal: fix bug that prevent display last user connection - refs #6105 #6262

New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Open
wants to merge 1 commit into
base: master
Choose a base branch
from
Open
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
2 changes: 1 addition & 1 deletion src/CoreBundle/EventListener/OnlineListener.php
Original file line number Diff line number Diff line change
Expand Up @@ -30,7 +30,7 @@ public function __construct(TokenStorageInterface $context, EntityManagerInterfa
/**
* Update the user "lastActivity" on each request.
*/
public function __invoke(ControllerEvent $event): void
public function onKernelController(ControllerEvent $event): void
{
/* Here we are checking that the current request is a "MASTER_REQUEST",
and ignore any subrequest in the process (for example when doing a
Expand Down
5 changes: 5 additions & 0 deletions src/CoreBundle/Resources/config/listeners.yml
Original file line number Diff line number Diff line change
Expand Up @@ -20,6 +20,11 @@ services:
tags:
- { name: kernel.event_listener, event: kernel.request, method: onKernelRequest }

# Log last user connection listener
Chamilo\CoreBundle\EventListener\OnlineListener:
tags:
- {name: kernel.event_listener, event: kernel.controller, method: onKernelController}


# Sets the user access in a course session listener
Chamilo\CoreBundle\EventListener\SessionAccessListener:
Expand Down
Loading