git://git.onelab.eu
/
plcapi.git
/ commitdiff
commit
grep
author
committer
pickaxe
?
search:
re
summary
|
shortlog
|
log
|
commit
| commitdiff |
tree
raw
|
patch
| inline |
side by side
(parent:
81290ef
)
- make sure to handle anon callers correctly
author
Tony Mack
<tmack@cs.princeton.edu>
Mon, 16 Jul 2007 20:00:09 +0000
(20:00 +0000)
committer
Tony Mack
<tmack@cs.princeton.edu>
Mon, 16 Jul 2007 20:00:09 +0000
(20:00 +0000)
PLC/Methods/GetNodes.py
patch
|
blob
|
history
diff --git
a/PLC/Methods/GetNodes.py
b/PLC/Methods/GetNodes.py
index
39dff8b
..
b0e8c0f
100644
(file)
--- a/
PLC/Methods/GetNodes.py
+++ b/
PLC/Methods/GetNodes.py
@@
-37,7
+37,9
@@
class GetNodes(Method):
# Remove admin only fields
if not isinstance(self.caller, Person) or \
'admin' not in self.caller['roles']:
- slice_ids = set(self.caller['slice_ids'])
+ slice_ids = set()
+ if self.caller:
+ slice_ids.update(self.caller['slice_ids'])
for node in nodes:
# if node has whitelist, make sure the user has a slice on the whitelist
if 'slice_ids_whitelist' in node and \