Skip navigation
Help

Query::__wakeup

7 query.inc public Query::__wakeup()

Implements the magic __wakeup function to reconnect to the database.

File

drupal/includes/database/query.inc, line 326
Non-specific Database query code. Used by all engines.

Code

public function __wakeup() {
  $this->connection = Database::getConnection($this->connectionTarget, $this->connectionKey);
}