/** * Restores the selected post. */ public function recover() { if (!$this->board->getModeratorPermission('canDeletePostCompletely')) { return; } if ($this->post != null && $this->post->isDeleted) { $this->post->restore(); $this->thread->checkVisibility(); $this->addPost(); } }