mirror of
https://gitee.com/IrisVega/frp.git
synced 2024-11-01 22:31:29 +08:00
let role default value to 'server'
This commit is contained in:
parent
92046a7ca2
commit
d873df5ca8
@ -632,6 +632,9 @@ func (cfg *StcpProxyConf) LoadFromFile(name string, section ini.Section) (err er
|
||||
}
|
||||
|
||||
tmpStr := section["role"]
|
||||
if tmpStr == "" {
|
||||
tmpStr = "server"
|
||||
}
|
||||
if tmpStr == "server" || tmpStr == "visitor" {
|
||||
cfg.Role = tmpStr
|
||||
} else {
|
||||
@ -721,6 +724,9 @@ func (cfg *XtcpProxyConf) LoadFromFile(name string, section ini.Section) (err er
|
||||
}
|
||||
|
||||
tmpStr := section["role"]
|
||||
if tmpStr == "" {
|
||||
tmpStr = "server"
|
||||
}
|
||||
if tmpStr == "server" || tmpStr == "visitor" {
|
||||
cfg.Role = tmpStr
|
||||
} else {
|
||||
|
Loading…
Reference in New Issue
Block a user