refactor: change singleton registrations to lazySingleton for improved performance
This commit is contained in:
@@ -68,7 +68,7 @@ class StaffProfileModule extends Module {
|
||||
|
||||
// Presentation layer - Cubit as singleton to avoid recreation
|
||||
// BlocProvider will use this same instance, preventing state emission after close
|
||||
i.addSingleton<ProfileCubit>(
|
||||
i.addLazySingleton<ProfileCubit>(
|
||||
() => ProfileCubit(
|
||||
i.get<GetStaffProfileUseCase>(),
|
||||
i.get<SignOutStaffUseCase>(),
|
||||
|
||||
Reference in New Issue
Block a user