X-Git-Url: http://git.onelab.eu/?a=blobdiff_plain;f=PLC%2FMethods%2FAdmGetSiteNodes.py;h=b366c80cc0e59a4ab4c980cb81d5ed0ce92e0ac1;hb=e499729c53c1bbfcfe3ec46043477f1e28c04119;hp=7eb822b99b20e6f6f1c8f1bd78799a237e31bd9f;hpb=94fc875fa77709f6b48e0a0ca46dfa1089ba2c92;p=plcapi.git diff --git a/PLC/Methods/AdmGetSiteNodes.py b/PLC/Methods/AdmGetSiteNodes.py index 7eb822b..b366c80 100644 --- a/PLC/Methods/AdmGetSiteNodes.py +++ b/PLC/Methods/AdmGetSiteNodes.py @@ -2,7 +2,7 @@ from PLC.Faults import * from PLC.Method import Method from PLC.Parameter import Parameter, Mixed from PLC.Sites import Site, Sites -from PLC.Auth import PasswordAuth +from PLC.Auth import Auth class AdmGetSiteNodes(Method): """ @@ -23,7 +23,7 @@ class AdmGetSiteNodes(Method): roles = ['admin', 'pi', 'user', 'tech'] accepts = [ - PasswordAuth(), + Auth(), [Mixed(Site.fields['site_id'], Site.fields['name'])], ] @@ -32,7 +32,7 @@ class AdmGetSiteNodes(Method): def call(self, auth, site_id_or_name_list = None): # Get site information - sites = Sites(self.api, site_id_or_name_list).values() + sites = Sites(self.api, site_id_or_name_list) if not sites: raise PLCInvalidArgument, "No such site"