From c676adde0b9cca81a90e762466f0e4f19ab53949 Mon Sep 17 00:00:00 2001 From: Julien Syx Date: Tue, 17 Mar 2015 17:57:18 +0100 Subject: [PATCH] Fix the issue #931 Checking that the parameter doesn't exist. The old code had a bug when the parameter was 0. --- lib/ansible/modules/cloud/amazon/ec2_asg.py | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/lib/ansible/modules/cloud/amazon/ec2_asg.py b/lib/ansible/modules/cloud/amazon/ec2_asg.py index 6e5d3508cb..c9c7987170 100644 --- a/lib/ansible/modules/cloud/amazon/ec2_asg.py +++ b/lib/ansible/modules/cloud/amazon/ec2_asg.py @@ -324,7 +324,7 @@ def create_autoscaling_group(connection, module): as_group = as_groups[0] changed = False for attr in ASG_ATTRIBUTES: - if module.params.get(attr): + if module.params.get(attr, None) is not None: module_attr = module.params.get(attr) if attr == 'vpc_zone_identifier': module_attr = ','.join(module_attr)