Remove duplicate null check

null check is done in ContainsKey()
This commit is contained in:
Vic 2022-12-29 11:17:29 +08:00
parent b5c48058cb
commit a40e15f727
2 changed files with 2 additions and 3 deletions

View file

@ -1,9 +1,8 @@
using System;
using System;
using System.Collections.Concurrent;
using System.Collections.Generic;
using System.Linq;
using System.Threading;
using System.Threading.Tasks;
using System.Windows.Media;
namespace Flow.Launcher.Infrastructure.Image

View file

@ -248,7 +248,7 @@ namespace Flow.Launcher.Infrastructure.Image
public static bool CacheContainImage(string path, bool loadFullImage = false)
{
return ImageCache.ContainsKey(path, loadFullImage) && ImageCache[path, loadFullImage] != null;
return ImageCache.ContainsKey(path, loadFullImage);
}
public static async ValueTask<ImageSource> LoadAsync(string path, bool loadFullImage = false)