PendingDbUpdates.php in Automatic Updates 7
File
ReadinessCheckers/PendingDbUpdates.php
View source
<?php
class PendingDbUpdates implements ReadinessCheckerInterface {
public static function run() {
$messages = [];
if (static::areDbUpdatesPending()) {
$messages[] = t('There are pending database updates. Please run update.php.');
}
return $messages;
}
protected static function areDbUpdatesPending() {
require_once DRUPAL_ROOT . '/includes/install.inc';
require_once DRUPAL_ROOT . '/includes/update.inc';
drupal_load_updates();
return (bool) update_get_update_list();
}
}