mirror of
https://gitee.com/dromara/mayfly-go
synced 2025-11-16 06:10:24 +08:00
refactor: api层尽可能屏蔽gin框架相关代码
This commit is contained in:
@@ -97,7 +97,7 @@ func useOtp(account *sysentity.Account, otpIssuer, accessToken string) (*OtpVeri
|
||||
|
||||
// 获取ip与归属地信息
|
||||
func getIpAndRegion(rc *req.Ctx) string {
|
||||
clientIp := rc.GinCtx.ClientIP()
|
||||
clientIp := rc.F.ClientIP()
|
||||
return fmt.Sprintf("%s %s", clientIp, netx.Ip2Region(clientIp))
|
||||
}
|
||||
|
||||
|
||||
Reference in New Issue
Block a user