mirror of
https://github.com/wyx2685/V2bX.git
synced 2026-02-04 04:30:08 +00:00
refactor NodeInfo
This commit is contained in:
@@ -46,7 +46,14 @@ func New(c *conf.ApiConfig) (*Client, error) {
|
||||
// Check node type
|
||||
c.NodeType = strings.ToLower(c.NodeType)
|
||||
switch c.NodeType {
|
||||
case "v2ray", "trojan", "shadowsocks", "hysteria":
|
||||
case "v2ray":
|
||||
c.NodeType = "vmess"
|
||||
case
|
||||
"vmess",
|
||||
"trojan",
|
||||
"shadowsocks",
|
||||
"hysteria",
|
||||
"vless":
|
||||
default:
|
||||
return nil, fmt.Errorf("unsupported Node type: %s", c.NodeType)
|
||||
}
|
||||
|
||||
Reference in New Issue
Block a user