2.3 KiB
2.3 KiB
TASK-064: Fixes from the full review — star double tap, diff lines
Status: implemented; required checks pass; not yet confirmed on a device Owner: Claude Reviewer: human product owner
Outcome
- A quick double tap on a repository's star no longer sends a star and an unstar together.
- A changed line whose own text starts with
--or++(an SQL or Lua comment, a Markdown---, a C++++i;at the start of a line) shows in the diff. Before, it was dropped, and the line numbers under it were off by one per dropped line. - A hunk header the parser cannot read leaves its rows unnumbered, instead of numbering them from 1.
Scope
- Included:
RepositoryListViewModel.toggleFavorite,UnifiedDiffParser. - Excluded: anything else the review looked at.
Writable paths
app/src/main/java/com/ubisam/ubgitea/feature/repositories/RepositoryListViewModel.ktapp/src/main/java/com/ubisam/ubgitea/domain/history/UnifiedDiffParser.ktapp/src/test/java/com/ubisam/ubgitea/feature/repositories/RepositoryListViewModelTest.ktapp/src/test/java/com/ubisam/ubgitea/domain/history/UnifiedDiffParserTest.kttasks/064-review-fixes-star-double-tap-and-diff-lines.mddocs/development-log.md
Acceptance criteria
- While a star or unstar request for a repository is on its way, another tap on that repository's star does nothing. After it settles, the next tap works as before.
- Inside a hunk,
+++xis an added++xand--- xis a removed-- x. The file's own---/+++lines, which come before the first hunk, are still skipped. - A hunk header that does not match
@@ -a[,b] +c[,d] @@gives rows with no line numbers, and its raw text is the hunk label. - Unit tests cover all three.
Security and privacy
No additional concerns.
Required checks
./gradlew compileDebugKotlin compileDebugUnitTestKotlin testDebugUnitTest assembleDebug lintDebug
Evidence
See the development log entry for TASK-064.
Review findings
Found by the full code review of 2026-09-29. Other reported candidates were checked against the code and dropped: the offline cache cannot show another account's list (every logout path clears it), state updates run on the main thread without a suspension between read and write, and the highlighter's patterns cannot match an empty string.