public function setLastPost(Post $post) { $this->last_time = $post->time; $this->last_user_id = $post->user_id; $this->last_post_id = $post->id; $this->last_post_number = $post->number; return $this; }