Prechádzať zdrojové kódy

made the bug fix more python-esq

Thomas Wiest 10 rokov pred
rodič
commit
35a8d1f73a
1 zmenil súbory, kde vykonal 1 pridanie a 1 odobranie
  1. 1 1
      bin/awsutil.py

+ 1 - 1
bin/awsutil.py

@@ -88,7 +88,7 @@ class AwsUtil(object):
         inst_by_env = {}
         for dns, host in inv['_meta']['hostvars'].items():
             # If you don't have an environment tag, we're going to ignore you
-            if not host.has_key('ec2_tag_environment'):
+            if 'ec2_tag_environment' not in host:
                 continue
 
             if host['ec2_tag_environment'] not in inst_by_env: