From 9729f1e78440b562b26c01d7801f0316bf86b379 Mon Sep 17 00:00:00 2001 From: nuno-aac Date: Fri, 20 Oct 2023 09:58:36 +0100 Subject: [PATCH] Update jobs sorting --- workspaces/cms-scripts/src/algolia.ts | 6 ++++++ 1 file changed, 6 insertions(+) diff --git a/workspaces/cms-scripts/src/algolia.ts b/workspaces/cms-scripts/src/algolia.ts index 234144fc48..bc7e350627 100644 --- a/workspaces/cms-scripts/src/algolia.ts +++ b/workspaces/cms-scripts/src/algolia.ts @@ -81,6 +81,12 @@ try { }) .wait(); } + + if (resourceName === "jobs") { + await index.setSettings({ + customRanking: ["desc(published_at_ts)"], + }); + } } } catch (err) { console.error(err);