feat: remove out name pixel drain

This commit is contained in:
Zamitto 2025-02-01 18:39:08 -03:00
parent 0820e4632b
commit df86a7716b
2 changed files with 1 additions and 7 deletions

View file

@ -40,7 +40,7 @@ const bundleBackup = async (
return tarLocation; return tarLocation;
}; };
export const uploadSaveGame = async ( const uploadSaveGame = async (
_event: Electron.IpcMainInvokeEvent, _event: Electron.IpcMainInvokeEvent,
objectId: string, objectId: string,
shop: GameShop, shop: GameShop,

View file

@ -16,7 +16,6 @@ import { logger } from "../logger";
import { db, downloadsSublevel, gamesSublevel, levelKeys } from "@main/level"; import { db, downloadsSublevel, gamesSublevel, levelKeys } from "@main/level";
import { sortBy } from "lodash-es"; import { sortBy } from "lodash-es";
import { TorBoxClient } from "./torbox"; import { TorBoxClient } from "./torbox";
import axios from "axios";
export class DownloadManager { export class DownloadManager {
private static downloadingGameId: string | null = null; private static downloadingGameId: string | null = null;
@ -276,16 +275,11 @@ export class DownloadManager {
case Downloader.PixelDrain: { case Downloader.PixelDrain: {
const id = download.uri.split("/").pop(); const id = download.uri.split("/").pop();
const name = await axios
.get(`https://pixeldrain.com/api/file/${id}/info`)
.then((res) => res.data.name as string);
return { return {
action: "start", action: "start",
game_id: downloadId, game_id: downloadId,
url: `https://cdn.pd5-gamedriveorg.workers.dev/api/file/${id}`, url: `https://cdn.pd5-gamedriveorg.workers.dev/api/file/${id}`,
save_path: download.downloadPath, save_path: download.downloadPath,
out: name,
}; };
} }
case Downloader.Qiwi: { case Downloader.Qiwi: {