Skip to content

Commit 65d3dcd

Browse files
committed
Lenient to missing atom_site.occupancy
1 parent 93c1c8f commit 65d3dcd

File tree

1 file changed

+1
-1
lines changed

1 file changed

+1
-1
lines changed

biojava-structure/src/main/java/org/biojava/nbio/structure/io/cif/CifStructureConsumerImpl.java

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -333,7 +333,7 @@ public void consumeAtomSite(AtomSite atomSite) {
333333
atom.setY(cartnY.get(atomIndex));
334334
atom.setZ(cartnZ.get(atomIndex));
335335

336-
atom.setOccupancy((float) occupancy.get(atomIndex));
336+
atom.setOccupancy((float) (occupancy.isDefined()? occupancy.get(atomIndex) : 1.0));
337337
atom.setTempFactor((float) bIsoOrEquiv.get(atomIndex));
338338

339339
if (altLocation == null || altLocation.isEmpty() || ".".equals(altLocation)) {

0 commit comments

Comments
 (0)