/// Compares the current instance with another object of the same type and returns an integer that indicates whether the current instance precedes, follows, or occurs in the same position in the sort order as the other object.
/// Compares the current instance with another object of the same type and returns an integer that indicates whether the current instance precedes, follows, or occurs in the same position in the sort order as the other object.
/// </summary>
/// </summary>
...
@@ -443,14 +429,14 @@ public int CompareTo(ClusterNode other)
...
@@ -443,14 +429,14 @@ public int CompareTo(ClusterNode other)
{
{
if(other==null)return-1;
if(other==null)return-1;
if(this.isSlave!=other.isSlave)returnisSlave?1:-1;// masters first
if(this.IsSlave!=other.IsSlave)returnIsSlave?1:-1;// masters first
if(isSlave)// both slaves? compare by parent, so we get masters A, B, C and then slaves of A, B, C
if(IsSlave)// both slaves? compare by parent, so we get masters A, B, C and then slaves of A, B, C