mirror of
https://github.com/elastic/logstash.git
synced 2025-04-24 14:47:19 -04:00
Fix the update command to only work with installed plugins gems so it's not having problems with not purged plugins
Fixes #3731
This commit is contained in:
parent
705ca73939
commit
a3fc9476cc
1 changed files with 1 additions and 1 deletions
|
@ -107,7 +107,7 @@ class LogStash::PluginManager::Update < LogStash::PluginManager::Command
|
|||
# retrieve only the latest spec for all locally installed plugins
|
||||
# @return [Hash] result hash {plugin_name.downcase => plugin_spec}
|
||||
def find_latest_gem_specs
|
||||
LogStash::PluginManager.find_plugins_gem_specs.inject({}) do |result, spec|
|
||||
LogStash::PluginManager.all_installed_plugins_gem_specs(gemfile).inject({}) do |result, spec|
|
||||
previous = result[spec.name.downcase]
|
||||
result[spec.name.downcase] = previous ? [previous, spec].max_by{|s| s.version} : spec
|
||||
result
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue