feat: add ALLOW_ADMIN_EXPORT to disable exporting of chats and the db

This commit is contained in:
Jun Siang Cheah
2024-04-17 09:33:22 +01:00
parent 1e76dbc9a0
commit 190b934ab5
6 changed files with 44 additions and 25 deletions

View File

@@ -52,6 +52,7 @@ from config import (
GLOBAL_LOG_LEVEL,
SRC_LOG_LEVELS,
WEBHOOK_URL,
ALLOW_ADMIN_EXPORT,
)
from constants import ERROR_MESSAGES
@@ -207,6 +208,7 @@ async def get_app_config():
"default_models": webui_app.state.DEFAULT_MODELS,
"default_prompt_suggestions": webui_app.state.DEFAULT_PROMPT_SUGGESTIONS,
"trusted_header_auth": bool(webui_app.state.AUTH_TRUSTED_EMAIL_HEADER),
"allow_admin_export": ALLOW_ADMIN_EXPORT,
}