fix: stream response (#3682)

* perf: supplement assistant empty response

* check array

* fix: stream response

* fix: model config cannot set to null
This commit is contained in:
Archer
2025-02-01 18:40:44 +08:00
committed by archer
parent 54defd8a3c
commit 9e100957eb
3 changed files with 42 additions and 17 deletions

View File

@@ -804,7 +804,7 @@ const ModelEditModal = ({
value={JSON.stringify(getValues('defaultConfig'), null, 2)}
onChange={(e) => {
if (!e) {
setValue('defaultConfig', undefined);
setValue('defaultConfig', {});
return;
}
try {
@@ -1014,7 +1014,7 @@ const ModelEditModal = ({
resize
onChange={(e) => {
if (!e) {
setValue('defaultConfig', undefined);
setValue('defaultConfig', {});
return;
}
try {