Fixed DI registration for MongoAlterationPlanStore (#5564)

This commit is contained in:
rosca-sabina 2024-06-09 18:36:36 +03:00 committed by GitHub
parent da7bff83b7
commit 5ebf4302d3
No known key found for this signature in database
GPG key ID: B5690EEEBB952194

View file

@ -3,6 +3,7 @@ using Elsa.Alterations.Features;
using Elsa.Features.Attributes;
using Elsa.Features.Services;
using Elsa.MongoDb.Common;
using Elsa.MongoDb.Modules.Alterations.Documents;
using Microsoft.Extensions.DependencyInjection;
namespace Elsa.MongoDb.Modules.Alterations;
@ -23,7 +24,10 @@ public class MongoAlterationsPersistenceFeature(IModule module) : PersistenceFea
{
base.Apply();
AddCollection<AlterationPlanDocument>("alteration_plans");
AddCollection<AlterationJob>("alteration_jobs");
AddStore<AlterationPlanDocument, MongoAlterationPlanStore>();
AddStore<AlterationJob, MongoAlterationJobStore>();
Services.AddHostedService<CreateIndices>();