Skip to content

Commit 4262ec5

Browse files
author
Vladimír Kleštinec
committed
Loggin exception
1 parent 20d0a81 commit 4262ec5

File tree

1 file changed

+1
-1
lines changed

1 file changed

+1
-1
lines changed

src/KubernetesClient/LeaderElection/LeaderElector.cs

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -214,7 +214,7 @@ private async Task AcquireAsync(CancellationToken cancellationToken)
214214
else
215215
{
216216
// else timeout
217-
_ = acq.ContinueWith(t => _ = t.Exception /* prevent UnobservedTaskException */, TaskContinuationOptions.OnlyOnFaulted);
217+
_ = acq.ContinueWith(t => OnError?.Invoke(t.Exception), TaskContinuationOptions.OnlyOnFaulted);
218218
}
219219
}
220220
finally

0 commit comments

Comments
 (0)