function Module::canUpdateDirectory

Same name in other branches
  1. 9 core/lib/Drupal/Core/Updater/Module.php \Drupal\Core\Updater\Module::canUpdateDirectory()
  2. 8.9.x core/lib/Drupal/Core/Updater/Module.php \Drupal\Core\Updater\Module::canUpdateDirectory()
  3. 10 core/lib/Drupal/Core/Updater/Module.php \Drupal\Core\Updater\Module::canUpdateDirectory()

Overrides UpdaterInterface::canUpdateDirectory

File

core/lib/Drupal/Core/Updater/Module.php, line 59

Class

Module
Defines a class for updating modules.

Namespace

Drupal\Core\Updater

Code

public static function canUpdateDirectory($directory) {
    $info = static::getExtensionInfo($directory);
    return isset($info['type']) && $info['type'] == 'module';
}

Buggy or inaccurate documentation? Please file an issue. Need support? Need help programming? Connect with the Drupal community.