Skip to content

Commit

Permalink
hotfix for reduce bug that only appeared in build
Browse files Browse the repository at this point in the history
cbartondock committed May 25, 2024
1 parent 42c8e02 commit b4fbb97
Showing 1 changed file with 3 additions and 3 deletions.
6 changes: 3 additions & 3 deletions src/lib/helpers/app-image/get-current-image.ts
Original file line number Diff line number Diff line change
@@ -20,9 +20,9 @@ export function getMaxLength(previewAppImage: PreviewDataAppImage, onlineImages:

const defaultLength = previewAppImage.default ? 1 : 0;

const singleLength = Object.values(singleLocalLengths).reduce((x,y) => x+y);
const multiLength = Object.values(multiLocalLengths).reduce((x,y) => x+y)
const onlineLength = Object.values(onlineLengths).reduce((x,y)=>x+y)
const singleLength = Object.values(singleLocalLengths).reduce((x,y) => x+y, 0);
const multiLength = Object.values(multiLocalLengths).reduce((x,y) => x+y, 0)
const onlineLength = Object.values(onlineLengths).reduce((x,y) => x+y, 0)
const maxLength = Math.max(defaultLength, singleLength + multiLength + onlineLength)
return { singleLocalLengths, multiLocalLengths, onlineLengths, defaultLength, onlineLength, singleLength, multiLength, maxLength }
}

0 comments on commit b4fbb97

Please sign in to comment.