dify / api /extensions /ext_proxy_fix.py
Severian's picture
initial commit
a8b3f00
raw
history blame
244 Bytes
from flask import Flask
from configs import dify_config
def init_app(app: Flask):
if dify_config.RESPECT_XFORWARD_HEADERS_ENABLED:
from werkzeug.middleware.proxy_fix import ProxyFix
app.wsgi_app = ProxyFix(app.wsgi_app)