Swap in structs.EqualPartitions for cmp

This commit is contained in:
freddygv 2021-10-26 15:35:32 -06:00
parent 1bade08f91
commit 4737ad118d
1 changed files with 1 additions and 1 deletions

View File

@ -506,7 +506,7 @@ func makeLoadAssignmentEndpointGroup(
gatewayKey = localKey
}
if gatewayKey.IsEmpty() || (localKey.Partition == target.Partition && localKey.Datacenter == target.Datacenter) {
if gatewayKey.IsEmpty() || (structs.EqualPartitions(localKey.Partition, target.Partition) && localKey.Datacenter == target.Datacenter) {
// Gateways are not needed if the request isn't for a remote DC or partition.
return loadAssignmentEndpointGroup{
Endpoints: realEndpoints,