diff --git a/mod/chat/chatd.php b/mod/chat/chatd.php
index 47a4297d90a..d576456245c 100644
--- a/mod/chat/chatd.php
+++ b/mod/chat/chatd.php
@@ -97,6 +97,45 @@ class ChatDaemon {
     public $setsinfo = array(); // Keyed by sessionid exactly like conn_sets, one of these for each of those.
     public $chatrooms = array(); // Keyed by chatid, holding arrays of data.
 
+    /** @var int error reporting level. */
+    public $_trace_level;
+
+    /** @var bool true if function_name exists and is a function, false otherwise. */
+    public $_pcntl_exists;
+
+    /** @var int */
+    public $_time_rest_socket;
+
+    /** @var string beep file location. */
+    public $_beepsoundsrc;
+
+    /** @var int update frequency records. */
+    public $_freq_update_records;
+
+    /** @var int upper limit value in seconds to detect a user has disconnected or not. */
+    public $_freq_poll_idle_chat;
+
+    /** @var resource|false a file pointer resource on success, or false on error. */
+    public $_stdout;
+
+    /** @var array user data with session ID as the key. */
+    public $sets_info = [];
+
+    /** @var array connection data with session ID as the key. */
+    public $conn_sets = [];
+
+    /** @var array connection data. */
+    public $conn_side = [];
+
+    /** @var array connection data. */
+    public $conn_half = [];
+
+    /** @var array connection data. */
+    public $conn_ufo = [];
+
+    /** @var resource|Socket socket resource. */
+    public $listen_socket;
+
     // IMPORTANT: $connectionssets, $setsinfo and $chatrooms must remain synchronized!
     //            Pay extra attention when you write code that affects any of them!
 
diff --git a/mod/chat/locallib.php b/mod/chat/locallib.php
index 06635fb8f3b..a21627f957d 100644
--- a/mod/chat/locallib.php
+++ b/mod/chat/locallib.php
@@ -35,6 +35,11 @@ class chat_portfolio_caller extends portfolio_module_caller_base {
     protected $start;
     /** @var int Timestamp */
     protected $end;
+    /** @var array Chat messages */
+    protected $messages = [];
+    /** @var bool True if participated, otherwise false. */
+    protected $participated;
+
     /**
      * @return array
      */