mirror of
https://github.com/tencentmusic/supersonic.git
synced 2025-12-10 11:07:06 +00:00
(fix)(chat-sdk) fix error when showcase return null (#636)
This commit is contained in:
@@ -31,7 +31,7 @@ const ShowCase: React.FC<Props> = ({ height, agentId, onSendMsg }) => {
|
||||
if (pageNoValue === 1) {
|
||||
setLoading(false);
|
||||
}
|
||||
const showCaseMapRes: any = res.data.showCaseMap;
|
||||
const showCaseMapRes: any = res.data.showCaseMap || [];
|
||||
const list = Object.keys(showCaseMapRes)
|
||||
.reduce((result: ShowCaseItemType[], key: string) => {
|
||||
result.push({ msgList: showCaseMapRes[key], caseId: key });
|
||||
|
||||
Reference in New Issue
Block a user