remember($this->getCacheKey(), 1, function () { return parent::runSelect(); }); } /** * Returns a Unique String that can identify this Query. * * @return string */ protected function getCacheKey() { return json_encode([ $this->toSql() => $this->getBindings(), ]); } }