mirror of
https://github.com/Flow-Launcher/Flow.Launcher.git
synced 2026-03-11 08:54:32 +00:00
Fix null exception
This commit is contained in:
parent
d9cc67ce6d
commit
067a51775e
1 changed files with 8 additions and 2 deletions
|
|
@ -1327,7 +1327,10 @@ namespace Flow.Launcher.ViewModel
|
|||
|
||||
private async Task QueryResultsAsync(bool searchDelay, bool isReQuery = false, bool reSelect = true)
|
||||
{
|
||||
await _updateSource?.CancelAsync();
|
||||
if (_updateSource != null)
|
||||
{
|
||||
await _updateSource.CancelAsync();
|
||||
}
|
||||
|
||||
App.API.LogDebug(ClassName, $"Start query with text: <{QueryText}>");
|
||||
|
||||
|
|
@ -1906,7 +1909,10 @@ namespace Flow.Launcher.ViewModel
|
|||
if (DialogJump.DialogJumpWindowPosition == DialogJumpWindowPositions.UnderDialog)
|
||||
{
|
||||
// Cancel the previous Dialog Jump task
|
||||
await _dialogJumpSource?.CancelAsync();
|
||||
if (_dialogJumpSource != null)
|
||||
{
|
||||
await _dialogJumpSource.CancelAsync();
|
||||
}
|
||||
|
||||
// Create a new cancellation token source
|
||||
_dialogJumpSource = new CancellationTokenSource();
|
||||
|
|
|
|||
Loading…
Reference in a new issue