We read every piece of feedback, and take your input very seriously.
To see all available qualifiers, see our documentation.
2 parents 3ff4dd1 + d262edb commit f7b1f33Copy full SHA for f7b1f33
1 file changed
lib/puppet/provider/rabbitmq_plugin/rabbitmqplugins.rb
@@ -21,8 +21,8 @@
21
defaultfor :feature => :posix
22
23
def self.instances
24
- rabbitmqplugins('list', '-E').split(/\n/).map do |line|
25
- if line.split(/\s+/)[1] =~ /^(\S+)$/
+ rabbitmqplugins('list', '-E', '-m').split(/\n/).map do |line|
+ if line =~ /^(\S+)$/
26
new(:name => $1)
27
else
28
raise Puppet::Error, "Cannot parse invalid plugins line: #{line}"
@@ -39,8 +39,8 @@ def destroy
39
end
40
41
def exists?
42
- rabbitmqplugins('list', '-E').split(/\n/).detect do |line|
43
- line.split(/\s+/)[1].match(/^#{resource[:name]}$/)
+ rabbitmqplugins('list', '-E', '-m').split(/\n/).detect do |line|
+ line.match(/^#{resource[:name]}$/)
44
45
46
0 commit comments