public function findPublishedById($id) { return $this->model->where('is_published', 1)->whereId($id)->firstOrFail(); }