Skip to content

Commit

Permalink
Update sync_cubit.dart
Browse files Browse the repository at this point in the history
  • Loading branch information
thiagocarvalhodev committed Nov 14, 2024
1 parent ec3797f commit 6199e30
Showing 1 changed file with 3 additions and 1 deletion.
4 changes: 3 additions & 1 deletion lib/sync/domain/cubit/sync_cubit.dart
Original file line number Diff line number Diff line change
Expand Up @@ -267,7 +267,9 @@ class SyncCubit extends Cubit<SyncState> {
' ${_lastSync!.difference(_initSync).inMilliseconds}ms to finish',
);

_promptToSnapshotBloc.add(const SyncRunning(isRunning: false));
if (!_promptToSnapshotBloc.isClosed) {
_promptToSnapshotBloc.add(const SyncRunning(isRunning: false));
}

unawaited(_updateContext());

Expand Down

0 comments on commit 6199e30

Please sign in to comment.