X-Git-Url: http://git.onelab.eu/?a=blobdiff_plain;f=PLC%2FRoles.py;h=86477668ed8c7423d4bd070263054429afe72653;hb=d316abf4bdb070ea1acf6be4b262c86a055b6ac2;hp=aad1019ef8a2e2e76b6304c2a66963bf2f7bce47;hpb=0cde91a55d0148022ac83bc4219cdefc66a56510;p=plcapi.git diff --git a/PLC/Roles.py b/PLC/Roles.py index aad1019..8647766 100644 --- a/PLC/Roles.py +++ b/PLC/Roles.py @@ -4,7 +4,7 @@ # Mark Huang # Copyright (C) 2006 The Trustees of Princeton University # -# $Id: Roles.py,v 1.6 2006/10/24 20:02:22 mlhuang Exp $ +# $Id: Roles.py,v 1.7 2006/11/08 23:02:01 mlhuang Exp $ # from types import StringTypes @@ -59,7 +59,7 @@ class Roles(Table): ", ".join(Role.fields) if role_filter is not None: - if isinstance(role_filter, list): + if isinstance(role_filter, (list, tuple, set)): # Separate the list into integers and strings ints = filter(lambda x: isinstance(x, (int, long)), role_filter) strs = filter(lambda x: isinstance(x, StringTypes), role_filter)