Skip to content

Commit

Permalink
fix: fix fmt
Browse files Browse the repository at this point in the history
  • Loading branch information
Han-Ya-Jun committed Dec 26, 2023
1 parent 661c664 commit 99f7c3d
Showing 1 changed file with 7 additions and 7 deletions.
14 changes: 7 additions & 7 deletions src/apisix/plugins/bk-components/bkauth.lua
Original file line number Diff line number Diff line change
Expand Up @@ -102,13 +102,13 @@ function _M.verify_app_secret(app_code, app_secret)
if result.code ~= 0 or res.status ~= 200 then
core.log.error(
string_format(
"failed to request %s,request_id: %s, result.code!=0 or status!=200, status: %s, response: %s", url,
"failed to request %s, request_id: %s, result.code!=0 or status!=200, status: %s, response: %s", url,
request_id, res.status,
res.body
)
)
return nil, string_format(
"failed to request third-party api, bkauth error message: %s, url: %s,request_id: %s, status: %s, code: %s",
"failed to request third-party api, bkauth error message: %s, url: %s, request_id: %s, status: %s, code: %s",
result.message, url, request_id, res.status, result.code
)
end
Expand Down Expand Up @@ -143,7 +143,7 @@ function _M.list_app_secrets(app_code)
)

if not (res and res.body) then
err = string_format("failed to request third-party api, url: %s,request_id: %s, err: %s, response: nil", url,
err = string_format("failed to request third-party api, url: %s, request_id: %s, err: %s, response: nil", url,
request_id, err)
core.log.error(err)
return nil, err
Expand All @@ -160,7 +160,7 @@ function _M.list_app_secrets(app_code)
if result == nil then
core.log.error(
string_format(
"failed to request %s,request_id: %s, response is not valid json, status: %s, response: %s", url,
"failed to request %s, request_id: %s, response is not valid json, status: %s, response: %s", url,
request_id, res.status, res.body
)
)
Expand Down Expand Up @@ -224,7 +224,7 @@ function _M.verify_access_token(access_token)
)

if not (res and res.body) then
err = string_format("failed to request third-party api, url: %s,request_id: %s, err: %s, response: nil", url,
err = string_format("failed to request third-party api, url: %s, request_id: %s, err: %s, response: nil", url,
request_id, err)
core.log.error(err)
return nil, err
Expand All @@ -234,12 +234,12 @@ function _M.verify_access_token(access_token)
if result == nil then
core.log.error(
string_format(
"failed to request %s,request_id: %s, response is not valid json, status: %s, response: %s", url,
"failed to request %s, request_id: %s, response is not valid json, status: %s, response: %s", url,
request_id, res.status, res.body
)
)
return nil, string_format(
"failed to request third-party api, response is not valid json, url: %s,request_id: %s, status: %s", url,
"failed to request third-party api, response is not valid json, url: %s, request_id: %s, status: %s", url,
request_id, res.status
)
end
Expand Down

0 comments on commit 99f7c3d

Please sign in to comment.