diff --git a/CHANGELOG.md b/CHANGELOG.md index d18e29d81b8cf4186dfbd644be2b39e0eea53325..42a2f159d670f750df3737abfd58d71b91bb8ebf 100644 --- a/CHANGELOG.md +++ b/CHANGELOG.md @@ -9,6 +9,7 @@ Note that since we don't clearly distinguish between a public and private interf - Check that model and coordinates have same element count when creating a trajectory - Fix aromatic rings assignment: do not mix flags and planarity test - Improve bonds assignment of coarse grained models: check for IndexPairBonds and exhaustive StructConn +- Fix unit mapping in bondedAtomicPairs MolScript query - Improve pdb parsing: handle non unique atom and chain names (fixes #156) ## [v3.5.0] - 2022-03-25 diff --git a/src/mol-model/structure/query/queries/generators.ts b/src/mol-model/structure/query/queries/generators.ts index 2fac1505e32f37a7403772b4fa39cb360e84a434..e963dc2a5b2eb62f408ccde5f5bbfbf000c9510e 100644 --- a/src/mol-model/structure/query/queries/generators.ts +++ b/src/mol-model/structure/query/queries/generators.ts @@ -353,7 +353,7 @@ export function bondedAtomicPairs(bondTest?: QueryPredicate): StructureQuery { atomicBond.a.unit = structure.unitMap.get(bond.unitA) as Unit.Atomic; atomicBond.a.element = atomicBond.a.unit.elements[bond.indexA]; atomicBond.aIndex = bond.indexA; - atomicBond.b.unit = structure.unitMap.get(bond.unitA) as Unit.Atomic; + atomicBond.b.unit = structure.unitMap.get(bond.unitB) as Unit.Atomic; atomicBond.b.element = atomicBond.b.unit.elements[bond.indexB]; atomicBond.bIndex = bond.indexB; atomicBond.order = bond.props.order;