From f75257acfb376b40d3cd5ba40b4d2d788f0c985b Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?Markus=20Ni=C3=9Fl?= Date: Wed, 26 Aug 2020 12:30:59 +0200 Subject: [PATCH] BindWithTransactionScopeAsync(Both/Left/Right) support Result --- .../Result/Extensions/BindWithTransactionScopeAsyncBoth.cs | 3 +++ .../Result/Extensions/BindWithTransactionScopeAsyncLeft.cs | 3 +++ .../Result/Extensions/BindWithTransactionScopeAsyncRight.cs | 3 +++ 3 files changed, 9 insertions(+) diff --git a/CSharpFunctionalExtensions/Result/Extensions/BindWithTransactionScopeAsyncBoth.cs b/CSharpFunctionalExtensions/Result/Extensions/BindWithTransactionScopeAsyncBoth.cs index b5c8439c..251e7fea 100644 --- a/CSharpFunctionalExtensions/Result/Extensions/BindWithTransactionScopeAsyncBoth.cs +++ b/CSharpFunctionalExtensions/Result/Extensions/BindWithTransactionScopeAsyncBoth.cs @@ -6,6 +6,9 @@ namespace CSharpFunctionalExtensions { public static partial class ResultExtensions { + public static Task> BindWithTransactionScope(this Task> self, Func>> f) + => WithTransactionScope(() => self.Bind(f)); + public static Task> BindWithTransactionScope(this Task> self, Func>> f) => WithTransactionScope(() => self.Bind(f)); diff --git a/CSharpFunctionalExtensions/Result/Extensions/BindWithTransactionScopeAsyncLeft.cs b/CSharpFunctionalExtensions/Result/Extensions/BindWithTransactionScopeAsyncLeft.cs index 04d7d317..3df187eb 100644 --- a/CSharpFunctionalExtensions/Result/Extensions/BindWithTransactionScopeAsyncLeft.cs +++ b/CSharpFunctionalExtensions/Result/Extensions/BindWithTransactionScopeAsyncLeft.cs @@ -6,6 +6,9 @@ namespace CSharpFunctionalExtensions { public static partial class ResultExtensions { + public static Task> BindWithTransactionScope(this Task> self, Func> f) + => WithTransactionScope(() => self.Bind(f)); + public static Task> BindWithTransactionScope(this Task> self, Func> f) => WithTransactionScope(() => self.Bind(f)); diff --git a/CSharpFunctionalExtensions/Result/Extensions/BindWithTransactionScopeAsyncRight.cs b/CSharpFunctionalExtensions/Result/Extensions/BindWithTransactionScopeAsyncRight.cs index 1c8d38e0..24651bc2 100644 --- a/CSharpFunctionalExtensions/Result/Extensions/BindWithTransactionScopeAsyncRight.cs +++ b/CSharpFunctionalExtensions/Result/Extensions/BindWithTransactionScopeAsyncRight.cs @@ -6,6 +6,9 @@ namespace CSharpFunctionalExtensions { public static partial class ResultExtensions { + public static Task> BindWithTransactionScope(this Result self, Func>> f) + => WithTransactionScope(() => self.Bind(f)); + public static Task> BindWithTransactionScope(this Result self, Func>> f) => WithTransactionScope(() => self.Bind(f));