File tree Expand file tree Collapse file tree 2 files changed +12
-2
lines changed
apps/miniprogram-agent-ui/miniprogram/components/agent-ui Expand file tree Collapse file tree 2 files changed +12
-2
lines changed Original file line number Diff line number Diff line change @@ -1425,7 +1425,12 @@ Component({
14251425 lastValue . knowledge_meta = [ ] ;
14261426 lastValue . content = this . data . defaultErrorMsg ;
14271427 if ( error && error . message ) {
1428- lastValue . error = error . message ;
1428+ if ( error . code === "EXCEED_TOKEN_QUOTA_LIMIT" ) {
1429+ lastValue . content = "大模型 Token 已耗尽,请通知开发者前往云开发平台进行处理" ;
1430+ lastValue . error = lastValue . content ;
1431+ } else {
1432+ lastValue . content = error . message ;
1433+ }
14291434 this . setData ( {
14301435 [ `chatRecords[${ lastValueIndex } ].error` ] : lastValue . error ,
14311436 } ) ;
Original file line number Diff line number Diff line change @@ -1425,7 +1425,12 @@ Component({
14251425 lastValue . knowledge_meta = [ ] ;
14261426 lastValue . content = this . data . defaultErrorMsg ;
14271427 if ( error && error . message ) {
1428- lastValue . error = error . message ;
1428+ if ( error . code === "EXCEED_TOKEN_QUOTA_LIMIT" ) {
1429+ lastValue . content = "大模型 Token 已耗尽,请通知开发者前往云开发平台进行处理" ;
1430+ lastValue . error = lastValue . content ;
1431+ } else {
1432+ lastValue . content = error . message ;
1433+ }
14291434 this . setData ( {
14301435 [ `chatRecords[${ lastValueIndex } ].error` ] : lastValue . error ,
14311436 } ) ;
You can’t perform that action at this time.
0 commit comments