mirror of
https://github.com/4gray/iptvnator.git
synced 2026-10-12 03:56:15 -08:00
fix(portals): absent is not empty, and every start claims the generation
Four more from review, three of them defects in last round's fixes. The restore normalizer materialized `sourcePins: []` for archives that never had the field, so "absent means no opinion" became "this archive says there are no pins" and a merge cleared the user's. Absent now stays absent. My test for that behaviour had passed for the wrong reason — it stubbed an empty pin list, so the clear was skipped whether or not the guard worked. `startGeneration` was claimed only by the switch path, so a plain Play, Resume or Restart could be overtaken by a switch still awaiting its close. Every start claims it now. Raw and normalized tokens were paired by position, which breaks when normalization drops a whole word: "FR: Ça" normalizes to "ca" and got handed the raw token "FR:", sending it down the ASCII branch it cannot match from. They are paired by normalized form instead. And the ambiguous yearless alias (`title:dune:`) is no longer written or retired beside a precise key — it may hold another remake's pre-enrichment pin. It stays available when it is the only key there is, since refusing to pin at all would be worse. Co-Authored-By: Claude Opus 5 <noreply@anthropic.com>
This commit is contained in:
1 parent
481d368019
commit
7c1b433d47
12 files changed
+147
-14
No files matched your search
@@ -468,8 +468,6 @@ describe('PlaylistRefreshActionService', () => {
|
||||
},
|
||||
],
|
||||
playbackPositions: [],
|
||||
// Normalized state always carries every collection, empty or not.
|
||||
sourcePins: [],
|
||||
});
|
||||
expect(store.dispatch).toHaveBeenCalledWith(
|
||||
PlaylistActions.updatePlaylistMeta({
|
||||
|
||||
@@ -555,8 +555,6 @@ describe('RecentPlaylistsComponent busy state', () => {
|
||||
},
|
||||
],
|
||||
playbackPositions: [],
|
||||
// Normalized state always carries every collection, empty or not.
|
||||
sourcePins: [],
|
||||
});
|
||||
expect(router.navigate).toHaveBeenCalledWith([
|
||||
'/workspace',
|
||||
|
||||
Reference in new issue
Block a user