mirror of
https://github.com/hydralauncher/hydra.git
synced 2025-03-09 15:40:26 +00:00
fix: removing repacks from worker threads to fix race condition
This commit is contained in:
parent
4559e23610
commit
ea923d5082
13 changed files with 71 additions and 105 deletions
|
@ -4,7 +4,8 @@ import flexSearch from "flexsearch";
|
|||
import type { GameShop, CatalogueEntry, SteamGame } from "@types";
|
||||
|
||||
import { getSteamAppAsset } from "@main/helpers";
|
||||
import { repacksWorker, steamGamesWorker } from "@main/workers";
|
||||
import { steamGamesWorker } from "@main/workers";
|
||||
import { RepacksManager } from "@main/services";
|
||||
|
||||
export interface SearchGamesArgs {
|
||||
query?: string;
|
||||
|
@ -29,11 +30,8 @@ export const searchSteamGames = async (
|
|||
name: "search",
|
||||
})) as SteamGame[];
|
||||
|
||||
const result = await repacksWorker.run(
|
||||
steamGames.map((game) => convertSteamGameToCatalogueEntry(game)),
|
||||
{
|
||||
name: "findRepacksForCatalogueEntries",
|
||||
}
|
||||
const result = RepacksManager.findRepacksForCatalogueEntries(
|
||||
steamGames.map((game) => convertSteamGameToCatalogueEntry(game))
|
||||
);
|
||||
|
||||
return orderBy(
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue