From b20bfc104863e7b2d90c1a639ae686dbd290eb84 Mon Sep 17 00:00:00 2001 From: The Magician Date: Wed, 28 Aug 2019 10:43:57 -0700 Subject: [PATCH] Bug fixes for GCP modules (#61359) --- lib/ansible/modules/cloud/google/gcp_spanner_database.py | 3 +++ 1 file changed, 3 insertions(+) diff --git a/lib/ansible/modules/cloud/google/gcp_spanner_database.py b/lib/ansible/modules/cloud/google/gcp_spanner_database.py index 0b54f498745..b2e8bd3a90e 100644 --- a/lib/ansible/modules/cloud/google/gcp_spanner_database.py +++ b/lib/ansible/modules/cloud/google/gcp_spanner_database.py @@ -158,6 +158,9 @@ def main(): fetch = fetch_resource(module, self_link(module)) changed = False + if 'instance' in module.params and 'name' in module.params['instance']: + module.params['instance']['name'] = module.params['instance']['name'].split('/')[-1] + if fetch: if state == 'present': if is_different(module, fetch):