Skip to content

Commit 0d9cce0

Browse files
committed
Fix wrong comparison with votes filtering
1 parent c19d6fe commit 0d9cce0

File tree

1 file changed

+2
-2
lines changed

1 file changed

+2
-2
lines changed

src/routes/getBranding.ts

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -181,7 +181,7 @@ async function filterAndSortBranding(videoID: VideoID, returnUserID: boolean, fe
181181
UUID: r.UUID,
182182
userID: returnUserID ? r.userID : undefined
183183
}))
184-
.filter((a) => fetchAll || a.votes > 0 || a.locked)
184+
.filter((a) => fetchAll || a.votes >= 0 || a.locked)
185185
.sort((a, b) => b.votes - a.votes)
186186
.sort((a, b) => +b.locked - +a.locked) as TitleResult[];
187187

@@ -197,7 +197,7 @@ async function filterAndSortBranding(videoID: VideoID, returnUserID: boolean, fe
197197
UUID: r.UUID,
198198
userID: returnUserID ? r.userID : undefined
199199
}))
200-
.filter((a) => fetchAll || a.votes > 0 || a.locked) as ThumbnailResult[];
200+
.filter((a) => fetchAll || a.votes >= 0 || a.locked) as ThumbnailResult[];
201201

202202
return {
203203
titles,

0 commit comments

Comments
 (0)