private function verify() { $post_slug = waRequest::param('post_url', false, waRequest::TYPE_STRING); $post_model = new blogPostModel(); $this->post = $post_model->getBySlug($post_slug); if (!$this->post || $this->post['status'] != blogPostModel::STATUS_PUBLISHED || !$this->post['comments_allowed']) { throw new waException(_w('Post not found'), 404); } if ($this->blog_id && !in_array($this->post['blog_id'], (array) $this->blog_id)) { throw new waException(_w('Post not found'), 404); } }