public function gc($lifetime) {
// get table/column
$dbTable = $this->dbOptions['db_table'];
$dbTimeCol = $this->dbOptions['db_time_col'];
// delete the session records that have expired
$sql = "DELETE FROM {$dbTable} WHERE {$dbTimeCol} < :time";
try {
$stmt = $this->pdo
->prepare($sql);
$stmt
->bindValue(':time', time() - $lifetime, \PDO::PARAM_INT);
$stmt
->execute();
} catch (\PDOException $e) {
throw new \RuntimeException(sprintf('PDOException was thrown when trying to manipulate session data: %s', $e
->getMessage()), 0, $e);
}
return true;
}