This commit is contained in:
TheXamlGuy
2024-05-18 20:40:12 +01:00
parent 46fe35fea4
commit 0f9998bc1d
54 changed files with 368 additions and 241 deletions
+3 -3
View File
@@ -7,12 +7,12 @@ namespace Bitvault;
public class CreateContainerHandler(IContainerFactory componentFactory,
IPublisher publisher) :
IHandler<CreateEventArgs<Container>, bool>
IHandler<CreateEventArgs<ContainerToken>, bool>
{
public async Task<bool> Handle(CreateEventArgs<Container> args,
public async Task<bool> Handle(CreateEventArgs<ContainerToken> args,
CancellationToken cancellationToken)
{
if (args.Value is Container container && container.Name is { Length: > 0 } name &&
if (args.Value is ContainerToken container && container.Name is { Length: > 0 } name &&
container.Password is { Length: > 0 } password)
{
if (componentFactory.Create(name) is IComponentHost host)