Merge pull request #1572 from xinnan-tech/hot-fix

update:优化报错信息
This commit is contained in:
欣南科技 2025-06-13 13:48:45 +08:00 committed by GitHub
commit 3b77e1ddf1
No known key found for this signature in database
GPG key ID: B5690EEEBB952194

View file

@ -55,11 +55,7 @@ class VisionHandler:
device_id = request.headers.get("Device-Id", "")
client_id = request.headers.get("Client-Id", "")
if device_id != token_device_id:
return web.Response(
text=json.dumps(self._create_error_response("设备ID与token不匹配")),
content_type="application/json",
status=401,
)
raise ValueError("设备ID与token不匹配")
# 解析multipart/form-data请求
reader = await request.multipart()