mirror of
https://github.com/status-im/consul.git
synced 2025-01-11 06:16:08 +00:00
use EqualPartitions
Signed-off-by: acpana <8968914+acpana@users.noreply.github.com>
This commit is contained in:
parent
0351ca5136
commit
6033584349
@ -408,7 +408,7 @@ func (s *Server) validatePeeringInPartition(remotePeerID, partition string) erro
|
|||||||
return fmt.Errorf("cannot read peering by ID: %w", err)
|
return fmt.Errorf("cannot read peering by ID: %w", err)
|
||||||
}
|
}
|
||||||
|
|
||||||
if peering != nil && peering.GetPartition() == partition {
|
if peering != nil && acl.EqualPartitions(peering.GetPartition(), partition) {
|
||||||
return fmt.Errorf("cannot create a peering within the same partition (ENT) or cluster (OSS)")
|
return fmt.Errorf("cannot create a peering within the same partition (ENT) or cluster (OSS)")
|
||||||
}
|
}
|
||||||
|
|
||||||
|
Loading…
x
Reference in New Issue
Block a user