mailr3892 - /1.3/generic_fns/selection.py


Others Months | Index by Date | Thread Index
>>   [Date Prev] [Date Next] [Thread Prev] [Thread Next]

Header


Content

Posted by edward on November 24, 2007 - 21:06:
Author: bugman
Date: Sat Nov 24 21:06:20 2007
New Revision: 3892

URL: http://svn.gna.org/viewcvs/relax?rev=3892&view=rev
Log:
Used the generic_fns.pipes.test() function a bit more.


Modified:
    1.3/generic_fns/selection.py

Modified: 1.3/generic_fns/selection.py
URL: 
http://svn.gna.org/viewcvs/relax/1.3/generic_fns/selection.py?rev=3892&r1=3891&r2=3892&view=diff
==============================================================================
--- 1.3/generic_fns/selection.py (original)
+++ 1.3/generic_fns/selection.py Sat Nov 24 21:06:20 2007
@@ -354,9 +354,8 @@
     @rtype:             bool
     """
 
-    # Test that the data pipe exists.
-    if relax_data_store.current_pipe not in relax_data_store.keys():
-        raise RelaxNoPipeError
+    # Test the data pipe.
+    pipes.test(relax_data_store.current_pipe)
 
     # Alias the data pipe container.
     cdp = relax_data_store[relax_data_store.current_pipe]
@@ -568,9 +567,8 @@
     if pipe == None:
         pipe = relax_data_store.current_pipe
 
-    # Test that the data pipe exists.
-    if pipe not in relax_data_store.keys():
-        raise RelaxNoPipeError, pipe
+    # Test the data pipe.
+    pipes.test(pipe)
 
     # Parse the selection string.
     select_obj = Selection(selection)
@@ -616,9 +614,8 @@
     if pipe == None:
         pipe = relax_data_store.current_pipe
 
-    # Test that the data pipe exists.
-    if pipe not in relax_data_store.keys():
-        raise RelaxNoPipeError, pipe
+    # Test the data pipe.
+    pipes.test(pipe)
 
     # Parse the selection string.
     select_obj = Selection(selection)
@@ -671,9 +668,8 @@
     if pipe == None:
         pipe = relax_data_store.current_pipe
 
-    # Test that the data pipe exists.
-    if pipe not in relax_data_store.keys():
-        raise RelaxNoPipeError, pipe
+    # Test the data pipe.
+    pipes.test(pipe)
 
     # Parse the selection string.
     select_obj = Selection(selection)




Related Messages


Powered by MHonArc, Updated Sat Nov 24 21:20:22 2007