diff --git a/src/models/home.model.ts b/src/models/home.model.ts index 0a7b6fdf..fa79c75e 100644 --- a/src/models/home.model.ts +++ b/src/models/home.model.ts @@ -177,8 +177,8 @@ export async function getFeed({ notes( where: { ${time ? `createdAt: { gt: "${time}" },` : ``} - stat: { is: { viewDetailCount: { gt: 0 } } }, - metadata: { is: { content: { path: "sources", array_contains: "xlog" }, AND: { content: { path: "tags", array_contains: "post" } } } } + stat: { viewDetailCount: { gt: 0 } }, + metadata: { content: { path: "sources", array_contains: "xlog" }, AND: { content: { path: "tags", array_contains: "post" } } } }, orderBy: { stat: { viewDetailCount: desc } }, take: 50, diff --git a/src/models/site.model.ts b/src/models/site.model.ts index 467ab596..e933bd20 100644 --- a/src/models/site.model.ts +++ b/src/models/site.model.ts @@ -109,7 +109,7 @@ export const getSites = async (input: number[]) => { content } } - notes( where: { characterId: { in: $identities }, createdAt: { gt: "${oneMonthAgo}" }, metadata: { is: { content: { path: "sources", array_contains: "xlog" } } } }, orderBy: [{ updatedAt: desc }] ) { + notes( where: { characterId: { in: $identities }, createdAt: { gt: "${oneMonthAgo}" }, metadata: { content: { path: "sources", array_contains: "xlog" } } }, orderBy: [{ updatedAt: desc }] ) { characterId createdAt }