Commit 06395c9b authored by David Mendez's avatar David Mendez
Browse files

init rate limiter after registering blueprints

parent bcaf7d9e
......@@ -42,7 +42,6 @@ def create_app():
with flask_app.app_context():
DB.init_app(flask_app)
CACHE.init_app(flask_app)
RATE_LIMITER.init_app(flask_app)
create_tables = RUN_CONFIG.get('sql_alchemy').get('create_tables', False)
if create_tables:
......@@ -58,6 +57,8 @@ def create_app():
flask_app.register_blueprint(ADMIN_AUTH_BLUEPRINT, url_prefix=f'{base_path}/admin')
flask_app.register_blueprint(ADMIN_TASKS_BLUEPRINT, url_prefix=f'{base_path}/admin')
RATE_LIMITER.init_app(flask_app)
return flask_app
if __name__ == '__main__':
......
Markdown is supported
0% or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment