Skip to content

Commit 320b407

Browse files
committed
return completed task if Refresh is null
1 parent f669433 commit 320b407

1 file changed

Lines changed: 1 addition & 1 deletion

File tree

Kerberos.NET/Cache/TicketCacheBase.cs

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -158,7 +158,7 @@ protected virtual async Task BackgroundCacheOperation()
158158

159159
if (cacheEntry != null && !cacheEntry.IsExpired(this.Configuration.Defaults.ClockSkew))
160160
{
161-
await (this.Refresh?.Invoke(cacheEntry))?.ConfigureAwait(false);
161+
await (this.Refresh?.Invoke(cacheEntry) ?? Task.CompletedTask).ConfigureAwait(false);
162162
}
163163
}
164164

0 commit comments

Comments
 (0)