Commit 1573479d authored by catch's avatar catch
Browse files

Issue #3376516 by andypost, quietone: Remove check for 10200 update from help module

(cherry picked from commit 5a3ca127)
parent 40743a89
Loading
Loading
Loading
Loading
Loading
+5 −7
Original line number Diff line number Diff line
@@ -148,11 +148,9 @@ function _help_search_update(array $extensions = []): void {
    return;
  }

  if (\Drupal::service('update.update_hook_registry')->getInstalledVersion('help') >= 10200) {
  // Ensure that topics for extensions that have been uninstalled are removed
  // and that the index state variable is updated.
  $help_search = \Drupal::service('plugin.manager.search')->createInstance('help_search');
  $help_search->updateTopicList();
  $help_search->updateIndexState();
}
}
+3 −2
Original line number Diff line number Diff line
@@ -58,8 +58,9 @@ public function setSearchManager(?PluginManagerInterface $search_manager = NULL)
   */
  public function clearCachedDefinitions() {
    parent::clearCachedDefinitions();
    $version = \Drupal::service('update.update_hook_registry')->getInstalledVersion('help');
    if ($this->searchManager && $version >= 10200) {
    // Search module may be missing. Help module might be installing,
    // so its search plugin may not be discovered yet.
    if ($this->searchManager && $this->searchManager->hasDefinition('help_search')) {
      // Rebuild the index on cache clear so that new help topics are indexed
      // and any changes due to help topics edits or translation changes are
      // picked up.