Skip to content

Commit 32b76f7

Browse files
committed
fix: cleanup [1316]
``` $ make busted-util /usr/local/openresty/luajit/bin/rover exec bin/busted "spec/threescale_utils_spec.lua" ●●● 3 successes / 0 failures / 0 errors / 0 pending : 0.023738 seconds ```
1 parent ad69ecc commit 32b76f7

File tree

2 files changed

+2
-2
lines changed

2 files changed

+2
-2
lines changed

gateway/src/apicast/threescale_utils.lua

+1-1
Original file line numberDiff line numberDiff line change
@@ -194,7 +194,7 @@ function _M.error(resilient, ...)
194194
else
195195
ngx.status = ngx.HTTP_INTERNAL_SERVER_ERROR
196196
ngx.say(...)
197-
if not resilient or resilient == nil then
197+
if not resilient then
198198
ngx.exit(ngx.status)
199199
end
200200
end

spec/threescale_utils_spec.lua

+1-1
Original file line numberDiff line numberDiff line change
@@ -16,7 +16,7 @@ describe('3scale utils', function()
1616
stub(ngx, 'say', function(...) return nil end)
1717
local exit = spy.on(ngx, 'exit', function(s) return 'exited!' end)
1818

19-
local error = _M.error(false, 'cache issue ' .. 'host:' .. 6379)
19+
local error = _M.error(nil, 'cache issue ' .. 'host:' .. 6379)
2020

2121
assert.spy(ngx.exit).was_called(1)
2222
assert.spy(ngx.say).was.called_with('cache issue ' .. 'host:' .. 6379)

0 commit comments

Comments
 (0)