diff --git a/client/src/components/MiningAreasPanel.jsx b/client/src/components/MiningAreasPanel.jsx index 8687555..aedc903 100644 --- a/client/src/components/MiningAreasPanel.jsx +++ b/client/src/components/MiningAreasPanel.jsx @@ -28,7 +28,8 @@ export default function MiningAreasPanel({ turtles, selectedTurtle, apiUrl }) { const response = await fetch(`${apiUrl}/api/mining-areas`); if (response.ok) { const data = await response.json(); - setAreas(data); + // Server returns a flat array of formatted areas + setAreas(Array.isArray(data) ? data : (data.areas || [])); } } catch (error) { console.error('Failed to load mining areas:', error);