You are here

public function SolrConnectorPluginBase::__sleep in Search API Solr 4.x

Same name and namespace in other branches
  1. 8.3 src/SolrConnector/SolrConnectorPluginBase.php \Drupal\search_api_solr\SolrConnector\SolrConnectorPluginBase::__sleep()
  2. 8 src/SolrConnector/SolrConnectorPluginBase.php \Drupal\search_api_solr\SolrConnector\SolrConnectorPluginBase::__sleep()
  3. 8.2 src/SolrConnector/SolrConnectorPluginBase.php \Drupal\search_api_solr\SolrConnector\SolrConnectorPluginBase::__sleep()

File

src/SolrConnector/SolrConnectorPluginBase.php, line 1226

Class

SolrConnectorPluginBase
Defines a base class for Solr connector plugins.

Namespace

Drupal\search_api_solr\SolrConnector

Code

public function __sleep() {

  // It's safe to unset the solr client completely before serialization
  // because connect() will set it up again correctly after deserialization.
  unset($this->solr);
  return parent::__sleep();
}