@@ -17,7 +17,7 @@ public partial class STATask
17
17
/// <param name="action">The work to execute in the STA thread.</param>
18
18
/// <param name="logger">Optional logger to capture any exception that occurs during execution.</param>
19
19
/// <returns>A <see cref="Task"/> that represents the work scheduled to execute in the STA thread.</returns>
20
- public static Task Run ( Action action , ILogger ? logger = null )
20
+ public static Task Run ( Action action , ILogger logger )
21
21
{
22
22
var tcs = new TaskCompletionSource ( ) ;
23
23
@@ -56,7 +56,7 @@ public static Task Run(Action action, ILogger? logger = null)
56
56
/// <param name="func">The work to execute in the STA thread.</param>
57
57
/// <param name="logger">Optional logger to capture any exception that occurs during execution.</param>
58
58
/// <returns>A <see cref="Task"/> that represents the work scheduled to execute in the STA thread.</returns>
59
- public static Task < T > Run < T > ( Func < T > func , ILogger ? logger = null )
59
+ public static Task < T > Run < T > ( Func < T > func , ILogger logger )
60
60
{
61
61
var tcs = new TaskCompletionSource < T > ( ) ;
62
62
@@ -93,7 +93,7 @@ public static Task<T> Run<T>(Func<T> func, ILogger? logger = null)
93
93
/// <param name="func">The work to execute in the STA thread.</param>
94
94
/// <param name="logger">Optional logger to capture any exception that occurs during execution.</param>
95
95
/// <returns>A <see cref="Task"/> that represents the work scheduled to execute in the STA thread.</returns>
96
- public static Task Run ( Func < Task > func , ILogger ? logger = null )
96
+ public static Task Run ( Func < Task > func , ILogger logger )
97
97
{
98
98
var tcs = new TaskCompletionSource ( ) ;
99
99
@@ -132,7 +132,7 @@ public static Task Run(Func<Task> func, ILogger? logger = null)
132
132
/// <param name="func">The work to execute in the STA thread.</param>
133
133
/// <param name="logger">Optional logger to capture any exception that occurs during execution.</param>
134
134
/// <returns>A <see cref="Task"/> that represents the work scheduled to execute in the STA thread.</returns>
135
- public static Task < T ? > Run < T > ( Func < Task < T > > func , ILogger ? logger = null )
135
+ public static Task < T ? > Run < T > ( Func < Task < T > > func , ILogger logger )
136
136
{
137
137
var tcs = new TaskCompletionSource < T ? > ( ) ;
138
138
0 commit comments