summaryrefslogtreecommitdiff
path: root/lib/google_api/cloud_platform/client.rb
diff options
context:
space:
mode:
Diffstat (limited to 'lib/google_api/cloud_platform/client.rb')
-rw-r--r--lib/google_api/cloud_platform/client.rb3
1 files changed, 2 insertions, 1 deletions
diff --git a/lib/google_api/cloud_platform/client.rb b/lib/google_api/cloud_platform/client.rb
index d13e3290cf5..926b7402cd5 100644
--- a/lib/google_api/cloud_platform/client.rb
+++ b/lib/google_api/cloud_platform/client.rb
@@ -65,7 +65,8 @@ module GoogleApi
end
def parse_operation_id(self_link)
- self_link.match(%r{projects/.*/zones/.*/operations/(.*)})[1]
+ m = self_link.match(%r{projects/.*/zones/.*/operations/(.*)})
+ m[1] if m
end
end
end