소스 검색

fix: buffer not return event show errors (#149)

tags/0.2.2
Joel 2 년 전
부모
커밋
2d0d3365ed
No account linked to committer's email address
1개의 변경된 파일1개의 추가작업 그리고 1개의 파일을 삭제
  1. 1
    1
      web/service/base.ts

+ 1
- 1
web/service/base.ts 파일 보기

@@ -78,7 +78,7 @@ const handleStream = (response: any, onData: IOnData, onCompleted?: IOnCompleted
if (message.startsWith('data: ')) { // check if it starts with data:
// console.log(message);
bufferObj = JSON.parse(message.substring(6)) // remove data: and parse as json
if (bufferObj.status === 400) {
if (bufferObj.status === 400 || !bufferObj.event) {
onData('', false, {
conversationId: undefined,
messageId: '',

Loading…
취소
저장