fix(runtime): address consolidated review feedback

This commit is contained in:
4gray committed 2026-05-22 14:02:56 +03:00
1 parent 582422c512
commit ed8680116c
17 files changed
+293 -35

No files matched your search

@@ -48,7 +48,7 @@
[players]="players()"
[streamFormatEnum]="streamFormatEnum"
[isDesktop]="isDesktop"
[supportsManagedExternalPlayers]="supportsManagedExternalPlayers"
[supportsManagedExternalPlayers]="supportsExternalPlayerPathSettings"
(selectRecordingFolder)="selectRecordingFolder()"
/>
@@ -934,10 +934,11 @@ describe('SettingsComponent', () => {
const clickSpy = jest
.spyOn(HTMLAnchorElement.prototype, 'click')
.mockImplementation();
let partialFileSaveFixture: ComponentFixture<SettingsComponent> | null =
null;
try {
const partialFileSaveFixture =
TestBed.createComponent(SettingsComponent);
partialFileSaveFixture = TestBed.createComponent(SettingsComponent);
const partialFileSaveComponent =
partialFileSaveFixture.componentInstance;
partialFileSaveComponent.checkAppVersion = jest.fn();
@@ -958,6 +959,7 @@ describe('SettingsComponent', () => {
expect(clickSpy).toHaveBeenCalled();
expect(revokeObjectURL).toHaveBeenCalledWith('blob:backup');
} finally {
partialFileSaveFixture?.destroy();
clickSpy.mockRestore();
Object.defineProperty(window.URL, 'createObjectURL', {
configurable: true,
@@ -612,7 +612,7 @@ export class SettingsComponent implements OnInit, OnDestroy {
if (!this.supportsEpg || !url) {
return;
}
void window.electron!.forceFetchEpg!(url);
void window.electron.forceFetchEpg(url);
}
/**
@@ -625,7 +625,7 @@ export class SettingsComponent implements OnInit, OnDestroy {
const urls = (this.epgUrl.value as string[])
.map((url) => url?.trim())
.filter((url): url is string => Boolean(url));
urls.forEach((url) => void window.electron!.forceFetchEpg!(url));
urls.forEach((url) => void window.electron.forceFetchEpg(url));
}
/**
@@ -666,7 +666,7 @@ export class SettingsComponent implements OnInit, OnDestroy {
this.isClearingEpgData.set(true);
try {
const result = await window.electron!.clearEpgData!();
const result = await window.electron.clearEpgData();
if (result && result.success === false) {
throw new Error('Clear EPG returned success=false');
}