def _gather_fieldsets(self):
        if not self.fieldsets:
            self.fieldsets = (('main', {'fields': self.form.fields.keys(),
                                        'legend': ''}),)
        for name, options in self.fieldsets:
            try:
                field_names = [n for n in options['fields']
                               if self.form.fields in n]
            except KeyError:
                message = "Fieldset definition must include 'fields' option."
                raise ValueError(message)
            boundfields = [forms.forms.BoundField(self.form,
                                                  self.form.fields[n], n)
                           for n in field_names]
            self._cached_fieldsets.append(Fieldset(self.form, name,
                boundfields, options.get('legend', None),
                ' '.join(options.get('classes', ())),
                options.get('description', '')))
dataset/ETHPy150Open carljm/django-form-utils/form_utils/forms.py/FieldsetCollection._gather_fieldsets/swapped operands of `in`