diff -u b/core/modules/system/system.module b/core/modules/system/system.module --- b/core/modules/system/system.module +++ b/core/modules/system/system.module @@ -870,10 +870,10 @@ $info[$module] = $data[$module]->info; } } - // Store the module info in cache. We rely on consecutive calls to - // system_rebuild_module_data() to reset this key, such as when - // listing modules, (un)installating modules, importing configuration, - // updating the site and when flushing all caches. + // Store the module information in cache. This cache is cleared by + // calling system_rebuild_module_data(), for example, when listing + // modules, (un)installing modules, importing configuration, updating + // the site and when flushing all the caches. \Drupal::cache()->set('system.module.info', $info); } } @@ -1016,8 +1016,8 @@ $modules = \Drupal::moduleHandler()->buildModuleDependencies($modules); $modules_cache = $modules; - // Store filenames to allow drupal_get_filename() to - // retrieve them without having to rebuild or scan the filesystem. + // Store filenames to allow drupal_get_filename() to retrieve them without + // having to rebuild or scan the filesystem. \Drupal::state()->set('system.module.files', $files); // Clear the module info cache. \Drupal::cache()->delete('system.module.info');