Import game refreshing metadata after installation

This commit is contained in:
Pat Hartl 2024-03-09 16:56:28 -06:00
parent 3464b12ee2
commit bb03809004
2 changed files with 5 additions and 1 deletions

View file

@ -350,6 +350,10 @@ namespace LANCommander.PlaynitePlugin
Plugin.PlayniteApi.Database.Games.Update(DownloadQueue.CurrentItem.Game);
var playSessions = Plugin.LANCommanderClient.Profile.GetPlaySessions(game.Id).Where(ps => ps.Start != null && ps.End != null).OrderByDescending(ps => ps.End);
Plugin.ImportController.ImportGame(manifest, playSessions);
ProcessQueue();
}

View file

@ -85,7 +85,7 @@ namespace LANCommander.PlaynitePlugin
return games;
}
private Game ImportGame(GameManifest manifest, IEnumerable<SDK.Models.PlaySession> playSessions)
public Game ImportGame(GameManifest manifest, IEnumerable<SDK.Models.PlaySession> playSessions)
{
bool exists = false;
var game = Database.Games.Get(manifest.Id);