Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

fix: episode progress tracking across seasons #140

Merged

Conversation

Simayon
Copy link
Contributor

@Simayon Simayon commented Nov 28, 2024

Description

Fixed an issue where watching an episode would incorrectly mark all episodes with the same number across different seasons as watched. For example, when a user watched part of an episode (e.g., S22E1), all Episode 1s across different seasons would incorrectly show the same progress.

Changes Made

Updated the episode matching logic in EpisodeCard.kt:

val episodeProgress = watchHistoryItem
    .episodesWatched
    .find {
        it.episodeId == data.id &&
        it.seasonNumber == data.season &&
        it.episodeNumber == data.number
    }

Fixes #136

Checklist:

  • [x ] I have followed the Conventional Commits guidelines for all my commits.
    • Example of a Conventional Commit message: feat: add new feature to enhance user experience

Fixes an issue where watching an episode would incorrectly mark all episodes with the same number across different seasons as watched. Now properly tracks progress by matching episode ID, season number, and episode number.
Copy link

sonarcloud bot commented Nov 28, 2024

Copy link
Collaborator

@rhenwinch rhenwinch left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

looks good

@rhenwinch
Copy link
Collaborator

don't mind the pr check, the current commits are not buildable

@rhenwinch rhenwinch merged commit c270c99 into flixclusiveorg:master Nov 28, 2024
1 of 2 checks passed
@Simayon Simayon deleted the fix/episode-progress-tracking branch November 28, 2024 13:04
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

Watch progress is being applied to every season
2 participants