public function paginate()
    {
        $this->count = $this->query->get()->count();
        $this->limit = $this->limit ?: $this->count;
        $this->query->skip($this->offset)->take($this->limit);
    }