Skip to content

Commit

Permalink
actually fix it
Browse files Browse the repository at this point in the history
  • Loading branch information
jamesmkrieger committed Nov 6, 2023
1 parent 00434d5 commit 39fd57e
Showing 1 changed file with 3 additions and 1 deletion.
4 changes: 3 additions & 1 deletion prody/proteins/pdbfile.py
Original file line number Diff line number Diff line change
Expand Up @@ -1243,8 +1243,10 @@ def writePDBStream(stream, atoms, csets=None, **kwargs):
NB: ChimeraX seems to prefer hybrid36 and may have problems with hexadecimal.
:type hybrid36: bool
"""
keepACSI = False
if hasattr(atoms, 'getACSIndex'):
initialACSI = atoms.getACSIndex()
keepACSI = True

renumber = kwargs.get('renumber', True)

Expand Down Expand Up @@ -1616,7 +1618,7 @@ def writePDBStream(stream, atoms, csets=None, **kwargs):

write('END ' + " "*74 + '\n')

if hasattr(atoms, 'setACSIndex'):
if keepACSI:
atoms.setACSIndex(initialACSI)

writePDBStream.__doc__ += _writePDBdoc
Expand Down

0 comments on commit 39fd57e

Please sign in to comment.