[DatFile] Null check!

This commit is contained in:
Matt Nadareski
2017-03-05 10:22:58 -08:00
parent eff85278d3
commit c3f42732a2

View File

@@ -431,6 +431,12 @@ namespace SabreTools.Helper.Dats
_files = new SortedDictionary<string, List<DatItem>>(); _files = new SortedDictionary<string, List<DatItem>>();
} }
// If the key is null, we return false since keys can't be null
if (key == null)
{
return false;
}
lock (_files) lock (_files)
{ {
return _files.ContainsKey(key); return _files.ContainsKey(key);