Skip to content

Commit c658a1e

Browse files
committed
refactor(app): clarify condition for user data fetching
- Update comments to explain the logic for fetching user data - Improve readability and understanding of the condition - Maintain existing functionality without code changes
1 parent b522580 commit c658a1e

File tree

1 file changed

+4
-4
lines changed

1 file changed

+4
-4
lines changed

lib/app/bloc/app_bloc.dart

Lines changed: 4 additions & 4 deletions
Original file line numberDiff line numberDiff line change
@@ -416,10 +416,10 @@ class AppBloc extends Bloc<AppEvent, AppState> {
416416
}
417417
}
418418

419-
// If not in demo mode, or if it was a migration (where data is already
420-
// fetched post-migration), perform the standard data fetch.
421-
// This avoids a redundant fetch in the demo initialization path,
422-
// which already fetches data.
419+
// Perform the standard data fetch if we are not in demo mode, or if a
420+
// migration just occurred (to load the migrated data).
421+
// This avoids a redundant fetch in the demo initialization path, which
422+
// handles its own data fetching after creating fixture data.
423423
if (!isDemoMode || isMigration) {
424424
await _fetchAndSetUserData(newUser, emit);
425425
}

0 commit comments

Comments
 (0)