Skip to content

Commit 969b3cc

Browse files
committed
Revert CancelAsync to Cancel
1 parent 8a2edf2 commit 969b3cc

File tree

1 file changed

+2
-8
lines changed

1 file changed

+2
-8
lines changed

Flow.Launcher/ViewModel/MainViewModel.cs

Lines changed: 2 additions & 8 deletions
Original file line numberDiff line numberDiff line change
@@ -1331,10 +1331,7 @@ private static List<Result> GetHistoryItems(IEnumerable<HistoryItem> historyItem
13311331

13321332
private async Task QueryResultsAsync(bool searchDelay, bool isReQuery = false, bool reSelect = true)
13331333
{
1334-
if (_updateSource != null)
1335-
{
1336-
await _updateSource.CancelAsync();
1337-
}
1334+
_updateSource?.Cancel();
13381335

13391336
App.API.LogDebug(ClassName, $"Start query with text: <{QueryText}>");
13401337

@@ -1913,10 +1910,7 @@ public async Task SetupDialogJumpAsync(nint handle)
19131910
if (DialogJump.DialogJumpWindowPosition == DialogJumpWindowPositions.UnderDialog)
19141911
{
19151912
// Cancel the previous Dialog Jump task
1916-
if (_dialogJumpSource != null)
1917-
{
1918-
await _dialogJumpSource.CancelAsync();
1919-
}
1913+
_dialogJumpSource?.Cancel();
19201914

19211915
// Create a new cancellation token source
19221916
_dialogJumpSource = new CancellationTokenSource();

0 commit comments

Comments
 (0)