diff --git a/app/chat/websocket.py b/app/chat/websocket.py index 97d5c0d..0dd4e07 100644 --- a/app/chat/websocket.py +++ b/app/chat/websocket.py @@ -136,15 +136,15 @@ manager = ConnectionManager() async def websocket_endpoint( chat_id: int, websocket: WebSocket, - authorization: Annotated[str | None, Header()] = None, + sec_websocket_protocol: Annotated[str | None, Header()] = None, # user: SUser = Depends(get_current_user_ws), uow=Depends(UnitOfWork) ): # await AuthService.check_verificated_user_with_exc(uow=uow, user_id=user.id) # await AuthService.validate_user_access_to_chat(uow=uow, user_id=user.id, chat_id=chat_id) await manager.connect(chat_id, websocket) - logging.critical(authorization) - await websocket.send_json({"headers": str(websocket.headers), "authorization": authorization}) + logging.critical(sec_websocket_protocol) + await websocket.send_json({"headers": str(websocket.headers), "authorization": sec_websocket_protocol}) try: while True: data = await websocket.receive_json()