checkTopic($id); return $this->handleTopic($topic); } protected function handleTopic(TopicModel $topic) { return [ 'id' => $topic->id, 'title' => $topic->title, 'topic' => $topic->cover, 'summary' => $topic->summary, 'published' => $topic->published, 'deleted' => $topic->deleted, 'create_time' => $topic->create_time, 'update_time' => $topic->update_time, ]; } }