Update ValidateEventArgs

This commit is contained in:
TheXamlGuy
2024-09-29 13:13:09 +01:00
parent 760ce933bd
commit 4b732791bd
2 changed files with 5 additions and 5 deletions
+4 -4
View File
@@ -2,9 +2,9 @@
public record Validate public record Validate
{ {
public static ValidateEventArgs<TValue> As<TValue>(TValue value) => public static ValidateEventArgs<TSender> As<TSender>(TSender sender) =>
new(value); new(sender);
public static ValidateEventArgs<TValue> As<TValue>() where TValue : new() => public static ValidateEventArgs<TSender> As<TSender>() where TSender : new() =>
new(new TValue()); new(new TSender());
} }
+1 -1
View File
@@ -1,3 +1,3 @@
namespace Toolkit.Foundation; namespace Toolkit.Foundation;
public record ValidateEventArgs<TValue>(TValue Value); public record ValidateEventArgs<TSender>(TSender? Sender = default);