use module name as imported to avoid exception
Traceback (most recent call last): File "run.py", line 2, in <module> from app import app File "/home/dev/flask-microblog/app/__init__.py", line 72, in <module> from app import views, models File "/home/dev/flask-microblog/app/views.py", line 9, in <module> from .forms import LoginForm, EditForm, PostForm, SearchForm File "/home/dev/flask-microblog/app/forms.py", line 5, in <module> from .models import User File "/home/dev/flask-microblog/app/models.py", line 113, in <module> whooshalchemy.whoosh_index(app, Post) NameError: name 'whooshalchemy' is not defined
This commit is contained in:
parent
dd4a0375c2
commit
7bc6d0c030
|
@ -110,4 +110,4 @@ class Post(db.Model):
|
||||||
|
|
||||||
|
|
||||||
if enable_search:
|
if enable_search:
|
||||||
whooshalchemy.whoosh_index(app, Post)
|
flask_whooshalchemy.whoosh_index(app, Post)
|
||||||
|
|
Loading…
Reference in New Issue