bin/check-rds.rb in sensu-plugins-aws-18.5.0 vs bin/check-rds.rb in sensu-plugins-aws-18.6.0
- old
+ new
@@ -321,12 +321,10 @@
def run
instances = []
if config[:db_cluster_id]
db_cluster_writer_id = find_db_cluster_writer(config[:db_cluster_id])
instances << find_db_instance(db_cluster_writer_id)
- end
-
- if config[:db_instance_id].nil? || config[:db_instance_id].empty?
+ elsif config[:db_instance_id].nil? || config[:db_instance_id].empty?
rds.describe_db_instances[:db_instances].map { |db| instances << db }
else
instances << find_db_instance(config[:db_instance_id])
end