Skip to content

Commit ce8257c

Browse files
committed
Fix bug: Exception handling in pdb reader
1 parent 943a135 commit ce8257c

File tree

1 file changed

+1
-1
lines changed

1 file changed

+1
-1
lines changed

AtomPacker/core/io/pdb/file.py

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -39,7 +39,7 @@ def load_pdb(filename: str, vdw: Optional[Dict[str, float]] = None) -> Universe:
3939
# Get van der Waals radii
4040
try:
4141
radii = _lookup_radii(universe.atoms.names, vdw)
42-
except AttributeError:
42+
except KeyError:
4343
radii = _lookup_radii(universe.atoms.elements, vdw)
4444

4545
# Add radii to topology

0 commit comments

Comments
 (0)