mirror of
https://github.com/ansible-collections/community.general.git
synced 2026-05-06 21:32:49 +00:00
Close all open filehandle (#50544)
Signed-off-by: Abhijeet Kasurde <akasurde@redhat.com>
This commit is contained in:
committed by
Brian Coca
parent
94a1d86d70
commit
db8702cdb8
@@ -115,8 +115,8 @@ def main():
|
||||
public_key = module.params['public_key']
|
||||
|
||||
if module.params['public_key_file']:
|
||||
public_key = open(module.params['public_key_file']).read()
|
||||
public_key = public_key.rstrip()
|
||||
with open(module.params['public_key_file']) as public_key_fh:
|
||||
public_key = public_key_fh.read().rstrip()
|
||||
|
||||
sdk, cloud = openstack_cloud_from_module(module)
|
||||
try:
|
||||
|
||||
Reference in New Issue
Block a user