function OnLoadPageData() { $authentication_manager = $this->GetAuthenticationManager(); $authentication_manager->ReadUserById(array($this->user->GetId())); $this->user = $authentication_manager->GetFirst(); if (!is_null($this->user)) { $topic_manager = new TopicManager($this->GetSettings(), $this->GetDataConnection()); $this->a_messages = $topic_manager->ReadMessagesByUser($this->user->GetId()); unset($topic_manager); } else { http_response_code(404); } }