0
0
mirror of https://github.com/honojs/hono.git synced 2024-11-24 11:07:29 +01:00

fix(ip-restriction): return the named function (#3113)

This commit is contained in:
Yusuke Wada 2024-07-08 23:32:04 +09:00 committed by GitHub
parent 71cdcf40d8
commit fbae337190
No known key found for this signature in database
GPG Key ID: B5690EEEBB952194

View File

@ -145,7 +145,7 @@ export const ipRestriction = (
}),
})
return async function (c, next) {
return async function ipRestriction(c, next) {
const connInfo = getIP(c)
const addr = typeof connInfo === 'string' ? connInfo : connInfo.remote.address
if (!addr) {