server/posts: commit reverse search population

This commit is contained in:
rr- 2017-02-02 19:45:18 +01:00
parent af6c35ed6b
commit cce543e0b6

View file

@ -1,12 +1,10 @@
''' Exports create_app. '''
import os
import time
import logging
import threading
import coloredlogs
import sqlalchemy.orm.exc
from szurubooru import config, errors, rest
from szurubooru import config, db, errors, rest
from szurubooru.func import posts, file_uploads
# pylint: disable=unused-import
from szurubooru import api, middleware
@ -113,6 +111,7 @@ def create_app():
try:
posts.populate_reverse_search()
db.session.commit()
except errors.ThirdPartyError:
pass