LANCommander/LANCommander.Server.ImportExport/Factories/ImportContextFactory.cs
Pat Hartl 54400fdb10 Refactor server importers
Refactors server importers to better handle dependencies on other data in the queue.
2025-12-03 02:22:37 -06:00

18 lines
No EOL
495 B
C#

using LANCommander.Server.ImportExport.Services;
using Microsoft.Extensions.DependencyInjection;
namespace LANCommander.Server.ImportExport.Factories;
public class ImportContextFactory(IServiceProvider serviceProvider)
{
public ImportContext Create()
{
var importService = serviceProvider.GetRequiredService<ImportService>();
var context = new ImportContext(serviceProvider);
importService.AddContext(context);
return context;
}
}