← back to Hotelwallcoverings
fix /api/facets total to report niche-filtered count, not pre-filter count
614017e24432d872e7fd4017b9ab01881da50944 · 2026-05-18 20:38:40 -0700 · Steve Abrams
Files touched
Diff
commit 614017e24432d872e7fd4017b9ab01881da50944
Author: Steve Abrams <steve@designerwallcoverings.com>
Date: Mon May 18 20:38:40 2026 -0700
fix /api/facets total to report niche-filtered count, not pre-filter count
---
server.js | 2 +-
1 file changed, 1 insertion(+), 1 deletion(-)
diff --git a/server.js b/server.js
index 2eeea90..89c5247 100644
--- a/server.js
+++ b/server.js
@@ -174,7 +174,7 @@ app.get('/api/facets', (req, res) => {
aesthetics[p.aesthetic] = (aesthetics[p.aesthetic] || 0) + 1;
vendors[p.vendor] = (vendors[p.vendor] || 0) + 1;
}
- res.json({ aesthetics, vendors, total: PRODUCTS.length });
+ res.json({ aesthetics, vendors, total: PRODUCTS_NICHE.length });
});
app.get('/api/health', (req, res) => res.json({ status: 'ok', count: PRODUCTS_NICHE.length, dropped: DROPPED }));
← bed9c08 hero-4grid: relocate json from data/ to public/ for Express
·
back to Hotelwallcoverings
·
fix non-functional sort select — pass state.sort to /api/pro 4b37eda →