diff --git a/flask_whooshee.py b/flask_whooshee.py index 1daccde..f250475 100644 --- a/flask_whooshee.py +++ b/flask_whooshee.py @@ -108,7 +108,7 @@ class Whooshee(object): model.query_class = WhoosheeQuery return wh - def register_model(self, analyzer=None, *index_fields): + def register_model(self, *index_fields, **kw): # construct subclass of AbstractWhoosheer for a model class ModelWhoosheer(AbstractWhoosheer): pass @@ -125,7 +125,7 @@ class Whooshee(object): primary = field.name schema_attrs[field.name] = whoosh.fields.NUMERIC(stored=True, unique=True) elif field.name in index_fields: - schema_attrs[field.name] = whoosh.fields.TEXT(analyzer=analyzer) + schema_attrs[field.name] = whoosh.fields.TEXT(**kw) mwh.schema = whoosh.fields.Schema(**schema_attrs) # we can't check with isinstance, because ModelWhoosheer is private # so use this attribute to find out