Code cleanup

This commit is contained in:
Jack251970 2025-03-22 23:12:20 +08:00
parent 9167cba636
commit b93faffdc0
2 changed files with 3 additions and 5 deletions

View file

@ -21,10 +21,8 @@ namespace Flow.Launcher.ViewModel
{ {
Settings = settings; Settings = settings;
if (result == null) if (result == null) return;
{
return;
}
Result = result; Result = result;
if (Result.Glyph is { FontFamily: not null } glyph) if (Result.Glyph is { FontFamily: not null } glyph)
@ -61,7 +59,6 @@ namespace Flow.Launcher.ViewModel
Glyph = glyph; Glyph = glyph;
} }
} }
} }
public Settings Settings { get; } public Settings Settings { get; }

View file

@ -28,6 +28,7 @@ namespace Flow.Launcher.ViewModel
Results = new ResultCollection(); Results = new ResultCollection();
BindingOperations.EnableCollectionSynchronization(Results, _collectionLock); BindingOperations.EnableCollectionSynchronization(Results, _collectionLock);
} }
public ResultsViewModel(Settings settings) : this() public ResultsViewModel(Settings settings) : this()
{ {
_settings = settings; _settings = settings;