Merge "Search for service by type"
diff --git a/functions-common b/functions-common
index 483b1fa..d6be1ec 100644
--- a/functions-common
+++ b/functions-common
@@ -806,7 +806,7 @@
     # Gets service id
     local service_id=$(
         # Gets service id
-        openstack service show $1 -f value -c id 2>/dev/null ||
+        openstack service show $2 -f value -c id 2>/dev/null ||
         # Creates new service if not exists
         openstack service create \
             $2 \