Merge branch 'master' of ssh://git.onelab.eu/git/sfa
[sfa.git] / sfa / server / sfaapi.py
index 79a5540..b783369 100644 (file)
@@ -238,6 +238,7 @@ class SfaApi (XmlrpcApi):
 
     def prepare_response_v2_am(self, result):
         response = {
+            'geni_api': 2,             
             'code': self.get_geni_code(result),
             'value': self.get_geni_value(result),
             'output': self.get_geni_output(result),
@@ -249,9 +250,8 @@ class SfaApi (XmlrpcApi):
         Converts the specified result into a standard GENI compliant 
         response  
         """
+        # as of dec 13 2011 we only support API v2
         if self.interface.lower() in ['aggregate', 'slicemgr']: 
-            if hasattr(self.config, 'SFA_AGGREGATE_API_VERSION') and \
-              self.config.SFA_AGGREGATE_API_VERSION == 2:
-                result = self.prepare_response_v2_am(result)
+            result = self.prepare_response_v2_am(result)
         return XmlrpcApi.prepare_response(self, result, method)