aboutsummaryrefslogtreecommitdiff
path: root/weed/shell/command_volume_fix_replication.go
diff options
context:
space:
mode:
authorchrislu <chris.lu@gmail.com>2023-11-09 08:02:57 -0800
committerchrislu <chris.lu@gmail.com>2023-11-09 08:02:57 -0800
commit85bed4d92e3bbb44db6ac4e6d17a3d2e079c226b (patch)
treeca4de2e4610e7a73e769d1125caface28db6f1a8 /weed/shell/command_volume_fix_replication.go
parentc563386675010969ddb6e75c604ea65427ab59c8 (diff)
parenta1c6f1fbd68b64a4546ea00d1adf33ada95f024b (diff)
downloadseaweedfs-85bed4d92e3bbb44db6ac4e6d17a3d2e079c226b.tar.xz
seaweedfs-85bed4d92e3bbb44db6ac4e6d17a3d2e079c226b.zip
Merge branch 'master' of https://github.com/seaweedfs/seaweedfs
Diffstat (limited to 'weed/shell/command_volume_fix_replication.go')
-rw-r--r--weed/shell/command_volume_fix_replication.go6
1 files changed, 3 insertions, 3 deletions
diff --git a/weed/shell/command_volume_fix_replication.go b/weed/shell/command_volume_fix_replication.go
index 43db0ff3b..9b6a64e6f 100644
--- a/weed/shell/command_volume_fix_replication.go
+++ b/weed/shell/command_volume_fix_replication.go
@@ -572,12 +572,12 @@ func isMisplaced(replicas []*VolumeReplica, replicaPlacement *super_block.Replic
for i := 0; i < len(replicas); i++ {
others := otherThan(replicas, i)
- if satisfyReplicaPlacement(replicaPlacement, others, *replicas[i].location) {
- return false
+ if !satisfyReplicaPlacement(replicaPlacement, others, *replicas[i].location) {
+ return true
}
}
- return true
+ return false
}