public function findOrFail($id)
    {
        $post = $this->find($id);

        if (! $post->getAdaptee()) {
            throw new QueryException("Posttype [{$this->getSlug()}] could not find post with id  [{$id}].");
        }

        return $post;
    }
public function findOrFail($id)
    {
        $post = $this->find($id);

        if (! $post->getAdaptee()) {
            throw new QueryException("Posttype [{$this->getSlug()}] could not find post with id  [{$id}].");
        }

        return $post;
    }
public function findOrFail ( $ id ) { $ post = $ this -> find ( $ id ) ; if ( ! $ post -> getAdaptee ( ) ) { throw new QueryException ( "Posttype [{$this->getSlug()}] could not find post with id  [{$id}]." ) ; } return $ post ; }
Find post by id or trow if unsuccessful.

@param int $id

@return \Assely\Adapter\Post
Find post by id or trow if unsuccessful .