← back to Metallicwallpaper
fix /api/facets total — use niche-filtered count not pre-niche PRODUCTS.length
a63b784f006e7d93aa382af5cebb50bb2d07128c · 2026-05-18 20:46:00 -0700 · Steve Abrams
Files touched
Diff
commit a63b784f006e7d93aa382af5cebb50bb2d07128c
Author: Steve Abrams <steve@designerwallcoverings.com>
Date: Mon May 18 20:46:00 2026 -0700
fix /api/facets total — use niche-filtered count not pre-niche PRODUCTS.length
---
server.js | 2 +-
1 file changed, 1 insertion(+), 1 deletion(-)
diff --git a/server.js b/server.js
index 5cdf59a..1cd8504 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 }));
← 83440f9 fix sort select — pass state.sort through to /api/products q
·
back to Metallicwallpaper
·
untrack 21 stale .bak/.pre- snapshots (17 in public/) + giti 66ef9c9 →