Skip to content

Commit 61ee542

Browse files
committed
Revert CancelAsync to Cancel
1 parent e01109d commit 61ee542

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
@@ -1334,10 +1334,7 @@ private static List<Result> GetHistoryItems(IEnumerable<HistoryItem> historyItem
13341334

13351335
private async Task QueryResultsAsync(bool searchDelay, bool isReQuery = false, bool reSelect = true)
13361336
{
1337-
if (_updateSource != null)
1338-
{
1339-
await _updateSource.CancelAsync();
1340-
}
1337+
_updateSource?.Cancel();
13411338
_progressQuery = null;
13421339

13431340
App.API.LogDebug(ClassName, $"Start query with text: <{QueryText}>");
@@ -1931,10 +1928,7 @@ public async Task SetupDialogJumpAsync(nint handle)
19311928
if (DialogJump.DialogJumpWindowPosition == DialogJumpWindowPositions.UnderDialog)
19321929
{
19331930
// Cancel the previous Dialog Jump task
1934-
if (_dialogJumpSource != null)
1935-
{
1936-
await _dialogJumpSource.CancelAsync();
1937-
}
1931+
_dialogJumpSource?.Cancel();
19381932

19391933
// Create a new cancellation token source
19401934
_dialogJumpSource = new CancellationTokenSource();

0 commit comments

Comments
 (0)