fix: 修复未知原因ws超时部分信息仍然没有拿到的问题

This commit is contained in:
ikechan8370 2023-03-07 23:00:19 +08:00
parent 7910110a6f
commit da04370ff5

View file

@ -320,7 +320,7 @@ export default class SydneyAIClient {
this.cleanupWebSocketConnection(ws) this.cleanupWebSocketConnection(ws)
if (replySoFar) { if (replySoFar) {
resolve({ resolve({
message message: replySoFar
}) })
} else { } else {
reject(new Error('Timed out waiting for response. Try enabling debug mode to see more information.')) reject(new Error('Timed out waiting for response. Try enabling debug mode to see more information.'))
@ -333,7 +333,7 @@ export default class SydneyAIClient {
this.cleanupWebSocketConnection(ws) this.cleanupWebSocketConnection(ws)
if (replySoFar) { if (replySoFar) {
resolve({ resolve({
message message: replySoFar
}) })
} else { } else {
reject('Request aborted') reject('Request aborted')