mirror of
https://github.com/ansible-collections/community.general.git
synced 2025-07-24 13:50:22 -07:00
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
This commit is contained in:
parent
f9ab9b4d68
commit
c2fb581414
12 changed files with 15 additions and 70 deletions
|
@ -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:
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue