api - Fixed loginPost handling

This commit is contained in:
Matthew Patrick 2022-05-17 13:31:03 +07:00
parent bb54ca0f17
commit 16614b4429

View file

@ -35,7 +35,7 @@ Future<dynamic> loginPost(data) async {
options: Options(
contentType: Headers.formUrlEncodedContentType,
validateStatus: (status) {
return status! < 400;
return status! < 500;
},
),
);
@ -85,6 +85,7 @@ Future<dynamic> checkoutPost(session, data) async {
}
Future<dynamic> subscribe(email) async {
var req = await Dio().get('$host/subscribe', queryParameters: {'email': email});
var req =
await Dio().get('$host/subscribe', queryParameters: {'email': email});
return req.statusCode;
}
}