Oops, fix error in modeling query on homepage

Okay, legit, I'm reading over this and I don't understand why `item_id`
isn't working here? It seems like we have `SELECT DISTINCT items.id AS
item_id`, and we use it in the `ORDER BY` clause right below. And I
don't see why, presumably, it's our item translations changes that
broke this?

But in any case, okay! This fixes it! Moving on!
This commit is contained in:
Emi Matchu 2024-02-27 17:33:01 -08:00
parent 6a6901ae39
commit 6b0f1853c3

View file

@ -460,7 +460,7 @@ async function runItemModelingQuery(db, filterToItemIds) {
} else {
// Or, to filter to certain items, we add their IDs to the WHERE clause.
const qs = filterToItemIds.map((_) => "?").join(", ");
itemIdsCondition = `(item_id IN (${qs}))`;
itemIdsCondition = `(items.id IN (${qs}))`;
itemIdsValues = filterToItemIds;
}