mirror of
https://gitee.com/spark-store-project/spark-store
synced 2026-06-22 14:13:49 +08:00
fix(account): keep download record pending through retry
This commit is contained in:
+2
-1
@@ -1265,13 +1265,14 @@ const handleInstallCompleteForDownloadRecord = async (
|
||||
const pendingRecord = pendingDownloadRecords.get(result.id);
|
||||
if (!pendingRecord) return;
|
||||
|
||||
pendingDownloadRecords.delete(result.id);
|
||||
if (!result.success || !isLoggedIn.value) return;
|
||||
|
||||
try {
|
||||
await recordDownloadedApp(pendingRecord);
|
||||
} catch (error: unknown) {
|
||||
logger.warn({ err: error }, "记录下载应用失败");
|
||||
} finally {
|
||||
pendingDownloadRecords.delete(result.id);
|
||||
}
|
||||
};
|
||||
|
||||
|
||||
Reference in New Issue
Block a user