1 cache.inc BackdropDatabaseCache::isEmpty()

Implements BackdropCacheInterface::isEmpty().

Overrides BackdropCacheInterface::isEmpty

File

core/includes/cache.inc, line 598
Functions and interfaces for cache handling.

Class

BackdropDatabaseCache
Defines a default cache implementation.

Code

function isEmpty() {
  $this->garbageCollection();
  $query = db_select($this->bin);
  $query->addExpression('1');
  $result = $query->range(0, 1)
    ->execute()
    ->fetchField();
  return empty($result);
}