TF-1115 Implement catch exception for HiveAccountDataSource

This commit is contained in:
dab246
2022-10-28 12:58:41 +07:00
committed by Dat H. Pham
parent c4eac83477
commit 4aad1c94ed
7 changed files with 38 additions and 17 deletions
@@ -49,6 +49,7 @@ import 'package:tmail_ui_user/features/login/domain/usecases/save_login_username
import 'package:tmail_ui_user/features/login/presentation/login_controller.dart';
import 'package:tmail_ui_user/features/manage_account/domain/usecases/log_out_oidc_interactor.dart';
import 'package:tmail_ui_user/main/bindings/network/binding_tag.dart';
import 'package:tmail_ui_user/main/exceptions/cache_exception_thrower.dart';
import 'package:tmail_ui_user/main/exceptions/remote_exception_thrower.dart';
class LoginBindings extends BaseBindings {
@@ -98,8 +99,8 @@ class LoginBindings extends BaseBindings {
Get.find<RemoteExceptionThrower>()
));
Get.lazyPut(() => HiveAccountDatasourceImpl(
Get.find<AccountCacheManager>()
));
Get.find<AccountCacheManager>(),
Get.find<CacheExceptionThrower>()));
Get.lazyPut(() => LoginUrlDataSourceImpl(
Get.find<RecentLoginUrlCacheClient>()
));