Permalink
Browse files

Fixed bug related to finding the right role from a list of roles.

  • Loading branch information...
1 parent 3d92a54 commit 6b0c270551e19cfdb5bbd0ff4e034de16dcfb745 @ncantor ncantor committed Jan 24, 2012
Showing with 1 addition and 1 deletion.
  1. +1 −1 lib/capify-ec2.rb
View
@@ -44,7 +44,7 @@ def desired_instances(region = nil)
end
def get_instances_by_role(role)
- desired_instances.select {|instance| instance.roles == role.to_s rescue false}
+ desired_instances.select {|instance| instance.roles.split(',').include?(role.to_s) rescue false}
end
def get_instances_by_region(roles, region)

0 comments on commit 6b0c270

Please sign in to comment.