mirror of
https://github.com/gethomepage/homepage.git
synced 2026-09-30 16:01:17 -07:00
Change: use status field as primary queue detail (#6859)
Docker CI / Docker Build & Push (push) Has been cancelled
Tests / vitest (3) (push) Has been cancelled
Tests / vitest (4) (push) Has been cancelled
Lint / Linting Checks (push) Has been cancelled
Release Drafter / Update Release Draft (push) Has been cancelled
Release Drafter / Auto Label PR (push) Has been cancelled
Tests / vitest (1) (push) Has been cancelled
Tests / vitest (2) (push) Has been cancelled
Docker CI / Docker Build & Push (push) Has been cancelled
Tests / vitest (3) (push) Has been cancelled
Tests / vitest (4) (push) Has been cancelled
Lint / Linting Checks (push) Has been cancelled
Release Drafter / Update Release Draft (push) Has been cancelled
Release Drafter / Auto Label PR (push) Has been cancelled
Tests / vitest (1) (push) Has been cancelled
Tests / vitest (2) (push) Has been cancelled
This commit is contained in:
@@ -36,8 +36,8 @@ const widget = {
|
||||
status: entry.status,
|
||||
}))
|
||||
.sort((a, b) => {
|
||||
const downloadingA = a.trackedDownloadState === "downloading";
|
||||
const downloadingB = b.trackedDownloadState === "downloading";
|
||||
const downloadingA = (a.status ?? a.trackedDownloadState) === "downloading";
|
||||
const downloadingB = (b.status ?? b.trackedDownloadState) === "downloading";
|
||||
if (downloadingA && !downloadingB) {
|
||||
return -1;
|
||||
}
|
||||
@@ -45,8 +45,8 @@ const widget = {
|
||||
return 1;
|
||||
}
|
||||
|
||||
const percentA = a.sizeLeft / a.size;
|
||||
const percentB = b.sizeLeft / b.size;
|
||||
const percentA = a.size > 0 ? a.sizeLeft / a.size : 1;
|
||||
const percentB = b.size > 0 ? b.sizeLeft / b.size : 1;
|
||||
if (percentA < percentB) {
|
||||
return -1;
|
||||
}
|
||||
|
||||
Reference in New Issue
Block a user