We read every piece of feedback, and take your input very seriously.
To see all available qualifiers, see our documentation.
1 parent 7b88cf0 commit a755439Copy full SHA for a755439
1 file changed
ml_rest_api/app.py
@@ -4,7 +4,7 @@
4
import warnings
5
from logging import Logger, getLogger
6
from flask import Flask
7
-from flask_wtf import CSRFProtect # pylint: disable=unused-import # type: ignore
+from flask_wtf import CSRFProtect # type: ignore
8
from ml_rest_api.logging_setup import setup_logging
9
from ml_rest_api.settings import get_value
10
from ml_rest_api.ml_trained_model.wrapper import trained_model_wrapper
@@ -39,6 +39,7 @@ def configure_app(flask_app: Flask) -> None:
39
def initialize_app(flask_app: Flask) -> None:
40
"""Initialises the app."""
41
configure_app(flask_app)
42
+ CSRFProtect(flask_app)
43
with warnings.catch_warnings():
44
# Temporarily suppressing a warning during registration of the Flask blueprint
45
warnings.filterwarnings(
0 commit comments