This is an automated email from the ASF dual-hosted git repository.

rabbah pushed a commit to branch master
in repository 
https://gitbox.apache.org/repos/asf/incubator-openwhisk-apigateway.git

The following commit(s) were added to refs/heads/master by this push:
       new  d4c47fa   fix v2 DELETE /apis (#212)
d4c47fa is described below

commit d4c47fac73b2e5953c25a8f2257aa9aee23d9be9
Author: Taylor King <taylorbradleyk...@gmail.com>
AuthorDate: Fri May 26 11:25:11 2017 -0400

    fix v2 DELETE /apis (#212)
---
 scripts/lua/lib/redis.lua              | 1 -
 scripts/lua/management/routes/apis.lua | 8 ++++----
 scripts/lua/oauth/google.lua           | 2 +-
 3 files changed, 5 insertions(+), 6 deletions(-)

diff --git a/scripts/lua/lib/redis.lua b/scripts/lua/lib/redis.lua
index c0b4d24..78caab4 100644
--- a/scripts/lua/lib/redis.lua
+++ b/scripts/lua/lib/redis.lua
@@ -29,7 +29,6 @@ local lrucache
 local CACHE_SIZE
 local CACHE_TTL
 local c, err
-
 local REDIS_HOST = os.getenv("REDIS_HOST")
 local REDIS_PORT = os.getenv("REDIS_PORT")
 local REDIS_PASS = os.getenv("REDIS_PASS")
diff --git a/scripts/lua/management/routes/apis.lua 
b/scripts/lua/management/routes/apis.lua
index d862c3a..5e70e4f 100644
--- a/scripts/lua/management/routes/apis.lua
+++ b/scripts/lua/management/routes/apis.lua
@@ -73,7 +73,7 @@ function getAPIs(dataStore)
       apiList = v2ApiList
     end
     apiList = (next(apiList) == nil) and "[]" or cjson.encode(apiList)
-    dataStore:close(ds)
+    dataStore:close()
     request.success(200, apiList)
   else
     local query = ngx.var.query
@@ -97,7 +97,7 @@ function getAPIs(dataStore)
         local returnObj = {
           artifact_id = api.id,
           managed_url = api.managedUrl,
-          open_api_doc = dataStore:getSwagger(ds, api.id)
+          open_api_doc = dataStore:getSwagger(api.id)
         }
         dataStore.close()
         request.success(200, cjson.encode(returnObj))
@@ -147,7 +147,7 @@ function addAPI(dataStore)
   end
   local managedUrlObj = apis.addAPI(dataStore, decoded, existingAPI)
   if version == 'v1' then
-    dataStore:close(ds)
+    dataStore:close()
     managedUrlObj = cjson.encode(managedUrlObj)
     request.success(200, managedUrlObj)
   elseif version == 'v2' then
@@ -168,7 +168,7 @@ function deleteAPI(dataStore)
     dataStore:close()
     request.err(400, "No id specified.")
   end
-  apis.deleteAPI(ds, id)
+  apis.deleteAPI(dataStore, id)
   local version = ngx.var.version
   if version == 'v1' then
     dataStore:close()
diff --git a/scripts/lua/oauth/google.lua b/scripts/lua/oauth/google.lua
index bea1f6c..74f5454 100644
--- a/scripts/lua/oauth/google.lua
+++ b/scripts/lua/oauth/google.lua
@@ -26,7 +26,7 @@ local utils = require "lib/utils"
 local redis = require "lib/redis"
 
 local _M = {} 
-function _M.process (ds, token)
+function _M.process (dataStore, token)
 
   local result = dataStore:getOAuthToken(dataStore, 'google', token) 
   

-- 
To stop receiving notification emails like this one, please contact
['"commits@openwhisk.apache.org" <commits@openwhisk.apache.org>'].

Reply via email to