Skip to content

Commit

Permalink
#230 - replace decimal numbers with integers at parking's page - make…
Browse files Browse the repository at this point in the history
… sure that free parking's slots're always => 0 - code cleanup
  • Loading branch information
mikolaj-jalocha committed Sep 25, 2024
1 parent 25cd3c9 commit 4fbb0d9
Showing 1 changed file with 2 additions and 1 deletion.
3 changes: 2 additions & 1 deletion lib/features/parkings_view/models/parking.dart
Original file line number Diff line number Diff line change
Expand Up @@ -42,7 +42,8 @@ class Parking with _$Parking implements GoogleNavigable {
return ParkingsConfig.rootUrl + photo.trim();
}

String get parsedNumberOfPlaces => numberOfPlaces.startsWith("-") ? "0" : numberOfPlaces;
String get parsedNumberOfPlaces =>
numberOfPlaces.startsWith("-") ? "0" : numberOfPlaces;

double get latitude => double.tryParse(geoLat) ?? 0;
double get longitude => double.tryParse(geoLan) ?? 0;
Expand Down

0 comments on commit 4fbb0d9

Please sign in to comment.