clean warnings

This commit is contained in:
2025-12-18 16:46:42 +01:00
parent ea6a9741ee
commit 6a9d68e945
3 changed files with 8 additions and 8 deletions

View File

@@ -64,21 +64,21 @@ class AuthRemoteDatasourceImpl implements AuthRemoteDatasource {
throw FormatException("No phone or email address given"); throw FormatException("No phone or email address given");
} }
late final Map<String, dynamic> body; // late final Map<String, dynamic> body;
if (email != null) { if (email != null) {
body = {'email': email}; // body = {'email': email};
return 'ec14b7e7-58dd-4a59-9f41-0da86eaabf14'; return 'ec14b7e7-58dd-4a59-9f41-0da86eaabf14';
} else { } else {
body = {'phone': phone!}; // body = {'phone': phone!};
return 'ec14b7e7-58dd-4a59-9f41-0da86eaabf14'; return 'ec14b7e7-58dd-4a59-9f41-0da86eaabf14';
throw Exception("reset by phone is not currently implemented"); // throw Exception("reset by phone is not currently implemented");
} }
final response = await _repository.put<Map<String, dynamic>>( /*final response = await _repository.put<Map<String, dynamic>>(
'/auth/reset-password', '/auth/reset-password',
body: body, body: body,
); );
final token = response.data!['token']; final token = response.data!['token'];
return token; return token;*/
} on DioException catch (error) { } on DioException catch (error) {
throw _mapDioError(error, defaultMessage: 'Error to request password reset'); throw _mapDioError(error, defaultMessage: 'Error to request password reset');
} }

View File

@@ -10,7 +10,7 @@ import 'package:utils/utils.dart';
class NewPasswordScreen extends ConsumerWidget { class NewPasswordScreen extends ConsumerWidget {
final NavigationContract navigationContract; final NavigationContract navigationContract;
const NewPasswordScreen({required this.navigationContract}); const NewPasswordScreen({super.key, required this.navigationContract});
@override @override
Widget build(BuildContext context, WidgetRef ref) { Widget build(BuildContext context, WidgetRef ref) {

View File

@@ -201,7 +201,7 @@ class RecoverPasswordViewModel extends Notifier<RecoverPasswordViewState> {
} }
Future<void> recoverPassword() async { Future<void> recoverPassword() async {
final String fullPhone = state.newDialCode + state.newPhoneNumber; //final String fullPhone = state.newDialCode + state.newPhoneNumber;
final String password = state.password; final String password = state.password;
if (!state.equalPasswords) { if (!state.equalPasswords) {