setItems method
Implementation
Future<void> setItems(List<T> items) async {
try {
emit(state.copy(isLoading: true));
await handler.inserts(data: items);
emit(state.copy(result: items, isLoading: false));
} catch (_) {
emit(state.copy(error: "Something went wrong!"));
rethrow;
}
}