mirror of
https://github.com/hydralauncher/hydra.git
synced 2026-01-23 19:01:02 +00:00
feat: apply suggestions
This commit is contained in:
@@ -1,6 +1,6 @@
|
||||
import { registerEvent } from "../register-event";
|
||||
import * as Sentry from "@sentry/electron/main";
|
||||
import { HydraApi, RPCManager, gamesPlaytime } from "@main/services";
|
||||
import { HydraApi, PythonInstance, gamesPlaytime } from "@main/services";
|
||||
import { dataSource } from "@main/data-source";
|
||||
import { DownloadQueue, Game, UserAuth } from "@main/entity";
|
||||
|
||||
@@ -24,7 +24,7 @@ const signOut = async (_event: Electron.IpcMainInvokeEvent) => {
|
||||
Sentry.setUser(null);
|
||||
|
||||
/* Disconnects libtorrent */
|
||||
RPCManager.killTorrent();
|
||||
PythonInstance.killTorrent();
|
||||
|
||||
await Promise.all([
|
||||
databaseOperations,
|
||||
|
||||
@@ -1,6 +1,6 @@
|
||||
import { gameRepository } from "@main/repository";
|
||||
import { registerEvent } from "../register-event";
|
||||
import { RPCManager, logger } from "@main/services";
|
||||
import { PythonInstance, logger } from "@main/services";
|
||||
import sudo from "sudo-prompt";
|
||||
import { app } from "electron";
|
||||
|
||||
@@ -16,7 +16,7 @@ const closeGame = async (
|
||||
_event: Electron.IpcMainInvokeEvent,
|
||||
gameId: number
|
||||
) => {
|
||||
const processes = await RPCManager.getProcessList();
|
||||
const processes = await PythonInstance.getProcessList();
|
||||
const game = await gameRepository.findOne({
|
||||
where: { id: gameId, isDeleted: false },
|
||||
});
|
||||
|
||||
Reference in New Issue
Block a user