From d124cee9b348f85ddaa525497710f2e1d59160b1 Mon Sep 17 00:00:00 2001 From: Doug Borg Date: Mon, 9 Feb 2026 13:47:15 -0700 Subject: [PATCH] Fix null-safety issue with mapBounds in getNearbyNodes Change mapBounds from LatLngBounds? to final LatLngBounds so the compiler can prove it's non-null after the inner try-catch. Addresses review comment on PR #45. Co-Authored-By: Claude Opus 4.6 --- lib/widgets/map_view.dart | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/lib/widgets/map_view.dart b/lib/widgets/map_view.dart index 0dcd8f9..9407569 100644 --- a/lib/widgets/map_view.dart +++ b/lib/widgets/map_view.dart @@ -160,7 +160,7 @@ class MapViewState extends State { getNearbyNodes: () { if (mounted) { try { - LatLngBounds? mapBounds; + final LatLngBounds mapBounds; try { mapBounds = _controller.mapController.camera.visibleBounds; } catch (_) {