diff options
author | Dag Wieers <dag@wieers.com> | 2019-02-05 01:44:45 +0100 |
---|---|---|
committer | Matt Clay <matt@mystile.com> | 2019-02-15 07:19:04 -0800 |
commit | c2fb581414b6fb60f411dba60e1930a658a6360e (patch) | |
tree | 09cd77f7dd2727d1feea4a2932c67c0080616a29 /contrib | |
parent | f9ab9b4d6851488b22ae2a017c13503aef26c7ea (diff) | |
download | ansible-c2fb581414b6fb60f411dba60e1930a658a6360e.tar.gz |
Fix various sonarcloud issues
This fixes various reported bugs through sonarcloud at:
https://sonarcloud.io/project/issues?id=Rodney-Reis_ansible&resolved=false&types=BUG
Diffstat (limited to 'contrib')
-rwxr-xr-x | contrib/inventory/gce.py | 21 |
1 files changed, 4 insertions, 17 deletions
diff --git a/contrib/inventory/gce.py b/contrib/inventory/gce.py index 59a3ccf246..e030a5fb12 100755 --- a/contrib/inventory/gce.py +++ b/contrib/inventory/gce.py @@ -1,20 +1,7 @@ #!/usr/bin/env python -# Copyright 2013 Google Inc. -# -# This file is part of Ansible -# -# Ansible is free software: you can redistribute it and/or modify -# it under the terms of the GNU General Public License as published by -# the Free Software Foundation, either version 3 of the License, or -# (at your option) any later version. -# -# Ansible is distributed in the hope that it will be useful, -# but WITHOUT ANY WARRANTY; without even the implied warranty of -# MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the -# GNU General Public License for more details. -# -# You should have received a copy of the GNU General Public License -# along with Ansible. If not, see <http://www.gnu.org/licenses/>. + +# Copyright: (c) 2013, Google Inc. +# GNU General Public License v3.0+ (see COPYING or https://www.gnu.org/licenses/gpl-3.0.txt) ''' GCE external inventory script @@ -498,7 +485,7 @@ class GceInventory(object): else: groups[machine_type] = [name] - image = node.image and node.image or 'persistent_disk' + image = node.image or 'persistent_disk' if image in groups: groups[image].append(name) else: |