test(feed): pin the sort options' default directions as literals

The feedSortOptions test compared each option's default direction against SORT_DEFAULT_DIR — the
implementation's own table, so a wrong entry passed — and that import was the export's only user
outside its module, which kept knip from seeing it had become dead after F3. The test now states the
directions, the table is private again.
This commit is contained in:
2026-09-11 03:19:17 +02:00
parent d349bc9084
commit 0b4b268678
2 changed files with 11 additions and 11 deletions
+1 -1
View File
@@ -36,7 +36,7 @@ const SORT_MAP: Record<Exclude<SortKey, "shuffle" | "relevance">, { asc: string;
priority: { desc: "priority", asc: "priority_asc" },
};
export const SORT_DEFAULT_DIR: Record<Exclude<SortKey, "shuffle" | "relevance">, "asc" | "desc"> = {
const SORT_DEFAULT_DIR: Record<Exclude<SortKey, "shuffle" | "relevance">, "asc" | "desc"> = {
date: "desc",
popular: "desc",
duration: "desc",