diff options
| author | xXJSONDeruloXx <danielhimebauch@gmail.com> | 2026-09-08 22:18:13 -0400 |
|---|---|---|
| committer | xXJSONDeruloXx <danielhimebauch@gmail.com> | 2026-09-08 22:18:13 -0400 |
| commit | 790132668c4421c68c32bdc8fc9792b0d6028f97 (patch) | |
| tree | 28542975b8a20f3ac4a86eb5594c129fbb6ca02d /src/utils/steamLaunchOptions.ts | |
| parent | bec26fe025c97c00d398e7a4fb571195706b9e76 (diff) | |
| download | decky-lsfg-vk-chore/migrate.tar.gz decky-lsfg-vk-chore/migrate.zip | |
I really dont want to but here you go little guychore/migrate
Diffstat (limited to 'src/utils/steamLaunchOptions.ts')
| -rw-r--r-- | src/utils/steamLaunchOptions.ts | 15 |
1 files changed, 14 insertions, 1 deletions
diff --git a/src/utils/steamLaunchOptions.ts b/src/utils/steamLaunchOptions.ts index 39125bd..82ff94b 100644 --- a/src/utils/steamLaunchOptions.ts +++ b/src/utils/steamLaunchOptions.ts @@ -1,5 +1,5 @@ // @ts-expect-error Node's built-in TypeScript loader requires explicit source extensions in tests. -import { cleanupLegacyLaunchOptions, isLegacyWrapperToken, normalizeLaunchOptions } from "./steamLaunchOptionParser.ts"; +import { cleanupLegacyLaunchOptions, cleanupPluginLaunchOptions, isLegacyWrapperToken, normalizeLaunchOptions } from "./steamLaunchOptionParser.ts"; // @ts-expect-error Node's built-in TypeScript loader requires explicit source extensions in tests. export * from "./steamLaunchOptionParser.ts"; @@ -203,6 +203,19 @@ export function cleanupSteamLaunchOptions( ): Promise<SteamLaunchOptionsSnapshot> { return queueSteamAppOperation(appId, nonSteam, async () => { const current = await readSteamLaunchOptions(appId, nonSteam); + const next = cleanupPluginLaunchOptions(current.options); + if (next === current.options) return current; + await setSteamLaunchOptions(appId, nonSteam, next); + return waitForLaunchOptions(appId, nonSteam, next); + }); +} + +export function cleanupLegacySteamLaunchOptions( + appId: number, + nonSteam: boolean, +): Promise<SteamLaunchOptionsSnapshot> { + return queueSteamAppOperation(appId, nonSteam, async () => { + const current = await readSteamLaunchOptions(appId, nonSteam); const next = cleanupLegacyLaunchOptions(current.options); if (next === current.options) return current; await setSteamLaunchOptions(appId, nonSteam, next); |
