How to get the details of the just logged-in user in the post_user_login
event in PyroCMS?
What I have tried:
$this->current_user
does not work, unless page is refreshed, even though the controllers are inheriting Public_Controller
or Admin_Controller
, thus implying availability of $this->current_user
(documentation).Why do I need this:
$data = $this->ci->current_user ? $this->ci->current_user : $this->ci->ion_auth->get_user();
Source: https://forum.pyrocms.com/discussion/25095/get-logged-in-user-in-post_user_login-event Author: andym