fix: share init error (#2690)

This commit is contained in:
Archer
2024-09-12 18:04:31 +08:00
committed by GitHub
parent 56281d92f2
commit da1126ed3c
4 changed files with 13 additions and 27 deletions

View File

@@ -18,6 +18,8 @@ export function transformPreviewHistories(histories: ChatItemType[]) {
export function addStatisticalDataToHistoryItem(historyItem: ChatItemType) {
if (historyItem.obj !== ChatRoleEnum.AI) return historyItem;
if (historyItem.totalQuoteList !== undefined) return historyItem;
// Flat children
const flatResData: ChatHistoryItemResType[] =
historyItem.responseData
?.map((item) => {