Store a copy of selection if possible for issue810
This commit is contained in:
1 parent
a4b9258b71
commit
bd9df98fe7
1 file changed
+4
-1
@@ -9,6 +9,9 @@ class Selection(Field):
|
||||
|
||||
def __init__(self, selection, string='', sort=True, translate=True, **args):
|
||||
super(Selection, self).__init__(string=string, **args)
|
||||
self.selection = selection
|
||||
if hasattr(selection, 'copy'):
|
||||
self.selection = selection.copy()
|
||||
else:
|
||||
self.selection = selection
|
||||
self.sort = sort
|
||||
self.translate_selection = translate
|
||||
Reference in new issue
Block a user