mirror of
https://github.com/ehang-io/nps.git
synced 2025-09-02 20:16:52 +00:00
Ip限制 npc代理连接
This commit is contained in:
@@ -241,3 +241,8 @@ func FormatAddress(s string) string {
|
||||
}
|
||||
return "127.0.0.1:" + s
|
||||
}
|
||||
|
||||
func GetIpByAddr(addr string) string {
|
||||
arr := strings.Split(addr, ":")
|
||||
return arr[0]
|
||||
}
|
||||
|
Reference in New Issue
Block a user