You are viewing a plain text version of this content. The canonical link for it is here.
Posted to notifications@apisix.apache.org by we...@apache.org on 2020/05/14 09:47:19 UTC
[incubator-apisix] branch master updated: chore: fix function name
typo in ip-restriction (#1586)
This is an automated email from the ASF dual-hosted git repository.
wenming pushed a commit to branch master
in repository https://gitbox.apache.org/repos/asf/incubator-apisix.git
The following commit(s) were added to refs/heads/master by this push:
new 3ad79cc chore: fix function name typo in ip-restriction (#1586)
3ad79cc is described below
commit 3ad79cccea2c260cba28a2d41ac53f9a2249b4b9
Author: 罗泽轩 <sp...@gmail.com>
AuthorDate: Thu May 14 17:47:09 2020 +0800
chore: fix function name typo in ip-restriction (#1586)
---
apisix/plugins/ip-restriction.lua | 6 +++---
1 file changed, 3 insertions(+), 3 deletions(-)
diff --git a/apisix/plugins/ip-restriction.lua b/apisix/plugins/ip-restriction.lua
index ab4deed..f08c9c7 100644
--- a/apisix/plugins/ip-restriction.lua
+++ b/apisix/plugins/ip-restriction.lua
@@ -110,7 +110,7 @@ function _M.check_schema(conf)
end
-local function create_ip_mather(ip_list)
+local function create_ip_matcher(ip_list)
local ip, err = ipmatcher.new(ip_list)
if not ip then
core.log.error("failed to create ip matcher: ", err,
@@ -128,7 +128,7 @@ function _M.access(conf, ctx)
if conf.blacklist and #conf.blacklist > 0 then
local matcher = lrucache(conf.blacklist, nil,
- create_ip_mather, conf.blacklist)
+ create_ip_matcher, conf.blacklist)
if matcher then
block = matcher:match(remote_addr)
end
@@ -136,7 +136,7 @@ function _M.access(conf, ctx)
if conf.whitelist and #conf.whitelist > 0 then
local matcher = lrucache(conf.whitelist, nil,
- create_ip_mather, conf.whitelist)
+ create_ip_matcher, conf.whitelist)
if matcher then
block = not matcher:match(remote_addr)
end