make ui at least usable throughout
Some checks failed
Build and release APK / Build APK (pull_request) Has been cancelled
Some checks failed
Build and release APK / Build APK (pull_request) Has been cancelled
This commit is contained in:
@@ -38,10 +38,18 @@ fetchTrip(
|
||||
String dataString = jsonEncode(data);
|
||||
log(dataString);
|
||||
|
||||
final response = await dio.post(
|
||||
"/trip/new",
|
||||
data: data
|
||||
);
|
||||
late Response response;
|
||||
try {
|
||||
response = await dio.post(
|
||||
"/trip/new",
|
||||
data: data
|
||||
);
|
||||
} catch (e) {
|
||||
trip.updateUUID("error");
|
||||
trip.updateError(e.toString());
|
||||
log(e.toString());
|
||||
return;
|
||||
}
|
||||
|
||||
// handle errors
|
||||
if (response.statusCode != 200) {
|
||||
|
Reference in New Issue
Block a user