prevent dup wallets

This commit is contained in:
TheXamlGuy
2024-07-23 18:20:58 +01:00
parent 43ad8c7ac2
commit 82e5982632
6 changed files with 57 additions and 2 deletions
+14
View File
@@ -0,0 +1,14 @@
namespace Toolkit.Foundation;
public record Result<TValue> :
Result
{
private readonly TValue? value;
protected internal Result(TValue? value, bool isSuccess, Error error)
: base(isSuccess, error) => this.value = value;
public TValue? Value => IsSuccess ? value! : default;
public static implicit operator Result<TValue>(TValue? value) => Create(value);
}