mirror of
https://github.com/ParisNeo/lollms-webui.git
synced 2024-12-18 20:17:50 +00:00
Update app.py
This commit is contained in:
parent
de97ab200b
commit
fe8ff061de
11
app.py
11
app.py
@ -89,7 +89,7 @@ from lollms.app import LollmsApplication
|
||||
from lollms.paths import LollmsPaths
|
||||
from lollms.main_config import LOLLMSConfig
|
||||
from lollms.utilities import trace_exception
|
||||
from lollms.security import sanitize_path, MultipartBoundaryCheck
|
||||
from lollms.security import sanitize_path
|
||||
from lollms_webui import LOLLMSWebUI
|
||||
from pathlib import Path
|
||||
from ascii_colors import ASCIIColors
|
||||
@ -124,9 +124,12 @@ def get_ip_addresses():
|
||||
app = FastAPI(title="LoLLMS", description="This is the LoLLMS-Webui API documentation")
|
||||
|
||||
|
||||
# Add the MultipartBoundaryCheck middleware
|
||||
app.add_middleware(MultipartBoundaryCheck)
|
||||
|
||||
try:
|
||||
from lollms.security import MultipartBoundaryCheck
|
||||
# Add the MultipartBoundaryCheck middleware
|
||||
app.add_middleware(MultipartBoundaryCheck)
|
||||
except:
|
||||
print("Couldn't activate MultipartBoundaryCheck")
|
||||
|
||||
#app.mount("/socket.io", StaticFiles(directory="path/to/socketio.js"))
|
||||
|
||||
|
Loading…
Reference in New Issue
Block a user