Pick the fix
The list screen shows the new title after an edit, but the detail screen shows the old one. Both call the API. Best fix?
Hint 1 of 1
How many places hold the data?
Choose an answer, then open Show answer below to check it.
Show answer
Answer: A Have the repository write results to Room and both screens observe the Room flow
Correct. One source of truth keeps every screen in sync.
Why not the others?
- B Refresh the detail screen on resume. Patches one case; drift continues elsewhere.
- C Pass the updated object between screens. Couples screens and breaks after process death.
- D Add an event bus to broadcast edits. Another channel that can get out of sync.