diff --git a/flatgfa/src/ops/depth.rs b/flatgfa/src/ops/depth.rs index 3d5ab66b..b46070d5 100644 --- a/flatgfa/src/ops/depth.rs +++ b/flatgfa/src/ops/depth.rs @@ -23,7 +23,7 @@ pub fn depth(gfa: &flatgfa::FlatGFA) -> (Vec, Vec) { for step in &gfa.steps[path.steps] { let seg_id = step.segment().index(); depths[seg_id] += 1; - if seen[seg_id] { + if !seen[seg_id] { // The first traversal of this path over this segment. uniq_depths[seg_id] += 1; seen.set(seg_id, true);