gen/genlib/record: fix connect

This commit is contained in:
Florent Kermarrec 2016-04-21 19:05:01 +02:00
parent e80cfedd7f
commit f6e1c45d57
1 changed files with 4 additions and 0 deletions

View File

@ -136,10 +136,14 @@ class Record:
_keep = set([f[0] for f in self.layout]) _keep = set([f[0] for f in self.layout])
elif isinstance(keep, list): elif isinstance(keep, list):
_keep = set(keep) _keep = set(keep)
else:
_keep = keep
if omit is None: if omit is None:
_omit = set() _omit = set()
elif isinstance(omit, list): elif isinstance(omit, list):
_omit = set(omit) _omit = set(omit)
else:
_omit = omit
_keep = _keep - _omit _keep = _keep - _omit