From d7bf3e22cb4c2c934079ba3f87179f9742acbda9 Mon Sep 17 00:00:00 2001 From: Your Name Date: Fri, 26 Dec 2025 01:40:11 -0500 Subject: [PATCH] Show fallback posts when bounds empty --- src/components/Map/usePostsEngine.js | 10 +++++----- 1 file changed, 5 insertions(+), 5 deletions(-) diff --git a/src/components/Map/usePostsEngine.js b/src/components/Map/usePostsEngine.js index fd4208e..0943321 100644 --- a/src/components/Map/usePostsEngine.js +++ b/src/components/Map/usePostsEngine.js @@ -537,6 +537,9 @@ export function usePostsEngine({ if (vBounded.length === 0 && viewParams?.center && viewParams?.radiusKm) { vBounded = filterByRadius(vAll, viewParams.center, viewParams.radiusKm * 1.2); } + if (vBounded.length === 0) { + vBounded = vAll; + } let v = vBounded; if (v.length > MAX_VISIBLE_POSTS) { const center = map?.getCenter?.(); @@ -723,15 +726,12 @@ export function usePostsEngine({ } } - const delay = initialLoadRef.current ? 0 : 2400; - initialLoadRef.current = false; if (moveDebounceRef.current) { clearTimeout(moveDebounceRef.current); moveDebounceRef.current = null; } - moveDebounceRef.current = setTimeout(() => { - if (!cancelled) load(); - }, delay); + initialLoadRef.current = false; + load(); return () => { cancelled = true; if (moveDebounceRef.current) {