Преглед на файлове

fix Assembly Symmetry Cluster coloring for deposited model

Alexander Rose преди 5 години
родител
ревизия
c5f336b0e4
променени са 1 файла, в които са добавени 4 реда и са изтрити 2 реда
  1. 4 2
      src/mol-model-props/rcsb/themes/assembly-symmetry-cluster.ts

+ 4 - 2
src/mol-model-props/rcsb/themes/assembly-symmetry-cluster.ts

@@ -59,11 +59,13 @@ export function AssemblySymmetryClusterColorTheme(ctx: ThemeDataContext, props:
             for (let j = 0, jl = members.length; j < jl; ++j) {
                 const asymId = members[j]!.asym_id
                 const operList = [...members[j]!.pdbx_struct_oper_list_ids || []] as string[]
-                if (operList.length === 0) operList.push('1') // TODO hack assuming '1' is the id of the identity operator
                 clusterByMember.set(clusterMemberKey(asymId, operList), i)
+                if (operList.length === 0) {
+                    operList.push('1') // TODO hack assuming '1' is the id of the identity operator
+                    clusterByMember.set(clusterMemberKey(asymId, operList), i)
+                }
             }
         }
-
         const palette = getPalette(clusters.length, props)
         legend = palette.legend