@@ -8,7 +8,6 @@ import 'package:flutter/cupertino.dart';
8
8
import 'package:flutter/material.dart' ;
9
9
import 'package:flutter_svg/svg.dart' ;
10
10
import 'package:geocoding/geocoding.dart' ;
11
- import 'package:geolocator/geolocator.dart' ;
12
11
import 'package:google_maps_flutter/google_maps_flutter.dart' ;
13
12
import 'package:in_app_review/in_app_review.dart' ;
14
13
import 'package:mosquito_alert_app/api/api.dart' ;
@@ -75,23 +74,6 @@ class Utils {
75
74
double ? lon,
76
75
String ? locationType,
77
76
}) async {
78
- if (lat == null && lon == null ) {
79
- bool locationEnabled = await Geolocator .isLocationServiceEnabled ();
80
- LocationPermission locPerm = await Geolocator .checkPermission ();
81
- bool hasLocationPermission = ! [
82
- LocationPermission .denied,
83
- LocationPermission .deniedForever
84
- ].contains (locPerm);
85
-
86
- if (locationEnabled && hasLocationPermission) {
87
- Position currentPosition = await Geolocator .getCurrentPosition (
88
- desiredAccuracy: LocationAccuracy .high);
89
- lat = currentPosition.latitude;
90
- lon = currentPosition.longitude;
91
- locationType = 'current' ;
92
- }
93
- }
94
-
95
77
if (session == null ) {
96
78
reportsList = [];
97
79
@@ -117,7 +99,6 @@ class Utils {
117
99
118
100
print (language);
119
101
session! .id = await ApiSingleton ().createSession (session! );
120
- // print("Session: ${jsonEncode(session.toJson())}");
121
102
}
122
103
123
104
if (session! .id != null ) {
0 commit comments