1 call to Files::get()
- Files::getMultiple in src/
State/ Files.php
File
-
src/
State/ Files.php, line 221
Class
- Files
- Provides AdvAgg with a file status state system using a key value store.
Namespace
Drupal\advagg\StateCode
public function get($key, $default = NULL) {
// https://api.drupal.org/api/drupal/core!lib!Drupal!Core!State!State.php/function/State::get/8.3.x
// Passthrough for Drupal 8.3+.
if (version_compare(\Drupal::VERSION, '8.3.0') >= 0) {
return parent::get($key, $default);
}
// https://api.drupal.org/api/drupal/core!lib!Drupal!Core!State!State.php/function/State::get/8.2.x
// Use State::getMultiple vs Files::getMultiple for older Drupal 8 versions.
$values = parent::getMultiple([
$key,
]);
return isset($values[$key]) ? $values[$key] : $default;
}