Author: bugman Date: Fri Jul 4 14:53:27 2008 New Revision: 6662 URL: http://svn.gna.org/viewcvs/relax?rev=6662&view=rev Log: Bug fix for the read_pdb() method. The structural object is only created if it does not yet exist. This bug was causing the loss of previously loaded files. Modified: branches/rdc_analysis/generic_fns/structure/main.py Modified: branches/rdc_analysis/generic_fns/structure/main.py URL: http://svn.gna.org/viewcvs/relax/branches/rdc_analysis/generic_fns/structure/main.py?rev=6662&r1=6661&r2=6662&view=diff ============================================================================== --- branches/rdc_analysis/generic_fns/structure/main.py (original) +++ branches/rdc_analysis/generic_fns/structure/main.py Fri Jul 4 14:53:27 2008 @@ -180,10 +180,11 @@ raise RelaxError, "The " + `parser` + " parser does not match the " + `cdp.structure.id` + " parser of the PDB loaded into the current pipe." # Place the parser specific structural object into the relax data store. - if parser == 'scientific': - cdp.structure = Scientific_data() - elif parser == 'internal': - cdp.structure = Internal() + if not hasattr(cdp, 'structure'): + if parser == 'scientific': + cdp.structure = Scientific_data() + elif parser == 'internal': + cdp.structure = Internal() # Load the structures. cdp.structure.load_pdb(file_path, model, verbosity)