Skip to content

Commit

Permalink
Bug fix: Crash when searching in the installed games search bar while…
Browse files Browse the repository at this point in the history
… the list was empty
  • Loading branch information
Yelo420 committed Dec 25, 2023
1 parent fadbdb2 commit 26e2e69
Show file tree
Hide file tree
Showing 3 changed files with 7 additions and 0 deletions.
1 change: 1 addition & 0 deletions CHANGELOG.md
Original file line number Diff line number Diff line change
Expand Up @@ -8,6 +8,7 @@ Recommended Gamevault Server Version: `v10.0.1`
- Bug fix: Standard release date filters did not work if no release year was set in existing games
- Bug fix: If the profile picture of another user has been changed, the profile picture has been changed in the top left-hand corner.
- Bug fix: Game Type is now displayed in more user friendly values
- Bug fix: Crash when searching in the installed games search bar while the list was empty

## 1.8.0
Recommended Gamevault Server Version: `v10.0.0`
Expand Down
5 changes: 5 additions & 0 deletions gamevault/UserControls/NewGameViewUserControl.xaml.cs
Original file line number Diff line number Diff line change
Expand Up @@ -95,6 +95,11 @@ private void GamePlay_Click(object sender, MouseButtonEventArgs e)
{
path = result.Value;
}
if(!File.Exists($"{path}\\gamevault-exec"))
{
MainWindowViewModel.Instance.AppBarText = $"Can not find part of '{path}'";
return;
}
string savedExecutable = Preferences.Get(AppConfigKey.Executable, $"{path}\\gamevault-exec");
string parameter = Preferences.Get(AppConfigKey.LaunchParameter, $"{path}\\gamevault-exec");
if (savedExecutable == string.Empty)
Expand Down
1 change: 1 addition & 0 deletions gamevault/UserControls/NewInstallUserControl.xaml.cs
Original file line number Diff line number Diff line change
Expand Up @@ -259,6 +259,7 @@ private void Search_TextChanged(object sender, TextChangedEventArgs e)
private void InputTimerElapsed(object sender, EventArgs e)
{
inputTimer.Stop();
if (NewInstallViewModel.Instance.InstalledGamesFilter == null) return;
NewInstallViewModel.Instance.InstalledGamesFilter.Filter = item =>
{
return ((KeyValuePair<Game, string>)item).Key.Title.Contains(inputTimer.Data, StringComparison.OrdinalIgnoreCase);
Expand Down

0 comments on commit 26e2e69

Please sign in to comment.