From: Tony Mack Date: Tue, 28 Nov 2006 01:02:15 +0000 (+0000) Subject: - fixed how node['slice_ids'] are filterd X-Git-Tag: pycurl-7_13_1~241 X-Git-Url: http://git.onelab.eu/?a=commitdiff_plain;h=16889a64d9fd498cca4dcd2705b28b2c0b7ea5c6;p=plcapi.git - fixed how node['slice_ids'] are filterd --- diff --git a/PLC/Methods/GetSlivers.py b/PLC/Methods/GetSlivers.py index 79f3d45..606df04 100644 --- a/PLC/Methods/GetSlivers.py +++ b/PLC/Methods/GetSlivers.py @@ -146,8 +146,8 @@ class GetSlivers(Method): # filter out any slices in this nodes slice_id list that may be invalid # (i.e. expired slices) - slice_ids = dict.fromkeys([slice['slice_id'] for slice in all_slice_ids]) - + slice_ids = dict.fromkeys(filter(lambda slice_id: slice_id in all_slice_ids, node['slice_ids'])) + # If not a foreign node, add all of our default system # slices to it. if node['peer_id'] is not None: