dart format
This commit is contained in:
@@ -142,24 +142,22 @@ class AuthService {
|
||||
return;
|
||||
}
|
||||
|
||||
Future setTncflag() async{
|
||||
Future setTncflag() async {
|
||||
try {
|
||||
final response = await _dio.post(
|
||||
'/api/auth/tnc',
|
||||
data: {"flag": 'Y'},
|
||||
);
|
||||
if (response.statusCode != 200) {
|
||||
if (response.statusCode != 200) {
|
||||
throw AuthException('Failed to proceed with T&C');
|
||||
}
|
||||
}
|
||||
on DioException catch (e) {
|
||||
} on DioException catch (e) {
|
||||
if (kDebugMode) {
|
||||
print(e.toString());
|
||||
}
|
||||
throw NetworkException('Network error during T&C Setup');
|
||||
} catch (e) {
|
||||
throw UnexpectedException(
|
||||
'Unexpected error: ${e.toString()}');
|
||||
throw UnexpectedException('Unexpected error: ${e.toString()}');
|
||||
}
|
||||
}
|
||||
}
|
||||
}
|
||||
|
||||
Reference in New Issue
Block a user