mirror of https://github.com/status-im/consul.git
Replace Split with SplitN
This commit is contained in:
parent
b9b6447977
commit
37a16e9487
|
@ -68,7 +68,7 @@ func (k GatewayKey) IsEmpty() bool {
|
||||||
}
|
}
|
||||||
|
|
||||||
func gatewayKeyFromString(s string) GatewayKey {
|
func gatewayKeyFromString(s string) GatewayKey {
|
||||||
split := strings.Split(s, ".")
|
split := strings.SplitN(s, ".", 2)
|
||||||
return GatewayKey{
|
return GatewayKey{
|
||||||
Partition: split[0],
|
Partition: split[0],
|
||||||
Datacenter: split[1],
|
Datacenter: split[1],
|
||||||
|
|
Loading…
Reference in New Issue