You are here

public static function DbHandler::selectExpired in Node expire 7.2

Returns expired node_expire records.

1 call to DbHandler::selectExpired()
CommonHookHandler::hookCron in src/Module/Hook/CommonHookHandler.php
Implements hook_cron().

File

src/Module/Db/DbHandler.php, line 81
DbHandler class.

Class

DbHandler
DbHandler class.

Namespace

Drupal\node_expire\Module\Db

Code

public static function selectExpired() {
  $result = db_query('SELECT n.nid, n.type FROM {node} n
      JOIN {node_expire} ne ON n.nid = ne.nid
      WHERE ne.expire <= :ne_expire', array(
    ':ne_expire' => REQUEST_TIME,
  ));
  return $result;
}