Skip to content

[Task] Remove stored Context references from StatisticsViewModel and SettingsViewModel #309

Description

@thatBeatrice

Holding Context in ViewModels can cause memory leaks and prevents ViewModels from being reused across platforms.

Acceptance Criteria:

  • @SuppressLint("StaticFieldLeak") annotations are removed from StatisticsViewModel and SettingsViewModel.
  • StatisticsViewModel returns raw numerical data; formatting logic resides in UI composables.
  • SettingsViewModel receives the app version string via constructor injection.
  • Toast notifications in Settings screen are triggered via state events in SettingsScreen.kt.

Metadata

Metadata

Assignees

No one assigned

    Labels

    No labels
    No labels

    Projects

    Status
    Backlog

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions