only attempt to update heatmap when enabled (fixes #45)

This commit is contained in:
Grant 2024-06-06 11:26:56 -06:00
parent b86c6735f2
commit dc62d7e3d7
1 changed files with 1 additions and 1 deletions

View File

@ -117,7 +117,7 @@ export const HeatmapOverlay = () => {
return;
}
updateHeatmap();
if (heatmapOverlay.enabled) updateHeatmap();
return () => {};
}, [canvasRef, heatmapOverlay.enabled, updateHeatmap]);