changeset 96:bfe4234ee6f4

better ordering of processing for dump()
author Jeff Hammel <jhammel@mozilla.com>
date Sun, 29 Apr 2012 01:05:49 -0700
parents 290c40224e5d
children 0c47bcb63048
files configuration/configuration.py
diffstat 1 files changed, 3 insertions(+), 2 deletions(-) [+]
line wrap: on
line diff
--- a/configuration/configuration.py	Sun Apr 29 00:30:58 2012 -0700
+++ b/configuration/configuration.py	Sun Apr 29 01:05:49 2012 -0700
@@ -420,12 +420,13 @@
     def dump(self, options, missingvalues):
         """dump configuration, if specified"""
 
+        if missingvalues:
+            self.error(str(missingvalues))
+
         dump = getattr(options, 'dump')
         if dump:
             # TODO: have a way of specifying format other than filename
             self.serialize(dump)
-        elif missingvalues:
-            self.error(str(missingvalues))
 
     ### serialization/deserialization