mirror of
https://github.com/hydralauncher/hydra.git
synced 2025-03-09 15:40:26 +00:00
feat: dispatching event when remote games are fetched
This commit is contained in:
parent
ca81281f1f
commit
944f3891bf
8 changed files with 31 additions and 17 deletions
|
@ -10,7 +10,7 @@ import { fetchDownloadSourcesAndUpdate } from "./helpers";
|
|||
import { publishNewRepacksNotifications } from "./services/notifications";
|
||||
import { MoreThan } from "typeorm";
|
||||
import { HydraApi } from "./services/hydra-api";
|
||||
import { getRemoteGames, uploadBatchGames } from "./services/library-sync";
|
||||
import { uploadGamesBatch } from "./services/library-sync";
|
||||
|
||||
startMainLoop();
|
||||
|
||||
|
@ -23,10 +23,7 @@ const loadState = async (userPreferences: UserPreferences | null) => {
|
|||
RealDebridClient.authorize(userPreferences?.realDebridApiToken);
|
||||
|
||||
HydraApi.setupApi().then(async () => {
|
||||
if (HydraApi.isLoggedIn()) {
|
||||
await uploadBatchGames();
|
||||
getRemoteGames();
|
||||
}
|
||||
if (HydraApi.isLoggedIn()) uploadGamesBatch();
|
||||
});
|
||||
|
||||
const [nextQueueItem] = await downloadQueueRepository.find({
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue