function system_update_8801
Remove 'path.temporary' config if redundant.
File
-
core/
modules/ system/ system.install, line 2639
Code
function system_update_8801() {
// If settings is already being used, or the config is set to the OS default,
// clear the config value.
$config = Drupal::configFactory()->getEditable('system.file');
if (Settings::get('file_temp_path') || $config->get('path.temporary') === FileSystemComponent::getOsTemporaryDirectory()) {
$config->clear('path.temporary')
->save(TRUE);
}
}
Buggy or inaccurate documentation? Please file an issue. Need support? Need help programming? Connect with the Drupal community.