import 'package:dartz/dartz.dart';
import 'package:food_delivery_client/core/exceptions/failure.dart';
import 'package:food_delivery_client/feature/auth/domain/repository/auth_repository.dart';
import 'package:food_delivery_client/feature/common/common.dart';
import 'package:food_delivery_client/food_delivery_client.dart';

import '../../../../core/usecase/usecase.dart';
@injectable
class ResetPasswordUseCase
    implements UseCase<SuccessModel, ResetPasswordParams> {
  final AuthRepository _authRepository;

  ResetPasswordUseCase(this._authRepository);

  @override
  Future<Either<Failure, SuccessModel>> call(ResetPasswordParams params) async {
    return _authRepository.resetPassword(params: params);
  }
}

class ResetPasswordParams {
  final String newPassword;
  final String phoneNumber;

  ResetPasswordParams({required this.newPassword, required this.phoneNumber});
}
