File tree Expand file tree Collapse file tree 1 file changed +4
-1
lines changed
descriptor/cip/src/main/java/org/openscience/cdk/geometry/cip/rules Expand file tree Collapse file tree 1 file changed +4
-1
lines changed Original file line number Diff line number Diff line change 2828import org .openscience .cdk .config .Isotopes ;
2929import org .openscience .cdk .config .IsotopeFactory ;
3030import org .openscience .cdk .geometry .cip .ILigand ;
31+ import org .openscience .cdk .interfaces .IIsotope ;
3132import org .openscience .cdk .tools .ILoggingTool ;
3233import org .openscience .cdk .tools .LoggingToolFactory ;
3334
@@ -63,7 +64,9 @@ private Integer getMassNumber(ILigand ligand) {
6364 Integer massNumber = ligand .getLigandAtom ().getMassNumber ();
6465 if (massNumber != null ) return massNumber ;
6566 if (factory == null ) return 0 ;
66- return factory .getMajorIsotope (ligand .getLigandAtom ().getSymbol ()).getMassNumber ();
67+ IIsotope isotope = factory .getMajorIsotope (ligand .getLigandAtom ().getSymbol ());
68+ if (isotope == null ) return 0 ;
69+ return isotope .getMassNumber ();
6770 }
6871
6972}
You can’t perform that action at this time.
0 commit comments