mirror of
https://github.com/comfyanonymous/ComfyUI.git
synced 2025-12-17 18:13:01 +08:00
added: Apply manager middleware
This commit is contained in:
parent
ad633b2953
commit
17cfabec7d
@ -36,6 +36,9 @@ from app.custom_node_manager import CustomNodeManager
|
|||||||
from typing import Optional, Union
|
from typing import Optional, Union
|
||||||
from api_server.routes.internal.internal_routes import InternalRoutes
|
from api_server.routes.internal.internal_routes import InternalRoutes
|
||||||
|
|
||||||
|
if not args.disable_manager:
|
||||||
|
import comfyui_manager
|
||||||
|
|
||||||
class BinaryEventTypes:
|
class BinaryEventTypes:
|
||||||
PREVIEW_IMAGE = 1
|
PREVIEW_IMAGE = 1
|
||||||
UNENCODED_PREVIEW_IMAGE = 2
|
UNENCODED_PREVIEW_IMAGE = 2
|
||||||
@ -175,6 +178,9 @@ class PromptServer():
|
|||||||
else:
|
else:
|
||||||
middlewares.append(create_origin_only_middleware())
|
middlewares.append(create_origin_only_middleware())
|
||||||
|
|
||||||
|
if not args.disable_manager:
|
||||||
|
middlewares.append(comfyui_manager.create_middleware())
|
||||||
|
|
||||||
max_upload_size = round(args.max_upload_size * 1024 * 1024)
|
max_upload_size = round(args.max_upload_size * 1024 * 1024)
|
||||||
self.app = web.Application(client_max_size=max_upload_size, middlewares=middlewares)
|
self.app = web.Application(client_max_size=max_upload_size, middlewares=middlewares)
|
||||||
self.sockets = dict()
|
self.sockets = dict()
|
||||||
|
|||||||
Loading…
Reference in New Issue
Block a user