adding support for geni_speaking_for option
[sfa.git] / sfa / methods / Stop.py
index 0d80282..654ac40 100644 (file)
@@ -26,7 +26,8 @@ class Stop(Method):
     
     def call(self, xrn, creds):
         hrn, type = urn_to_hrn(xrn)
-        valid_creds = self.api.auth.checkCredentials(creds, 'stopslice', hrn)
+        (speaking_for, _) = urn_to_hrn(options.get('geni_speaking_for'))
+        valid_creds = self.api.auth.checkCredentials(creds, 'stopslice', hrn, speaking_for)
 
         #log the call
         origin_hrn = Credential(string=valid_creds[0]).get_gid_caller().get_hrn()