Handle as many warnings as possible

This commit is contained in:
Matt Nadareski
2024-04-24 16:08:17 -04:00
parent b8b5e6595a
commit a271727e2c
46 changed files with 669 additions and 661 deletions

View File

@@ -268,7 +268,7 @@ namespace SabreTools.FileTypes.Archives
public override bool IsTorrent()
{
// Check for the file existing first
if (!File.Exists(this.Filename))
if (this.Filename == null || !File.Exists(this.Filename))
return false;
string datum = Path.GetFileName(this.Filename).ToLowerInvariant();
@@ -290,7 +290,7 @@ namespace SabreTools.FileTypes.Archives
public BaseFile? GetTorrentXZFileInfo()
{
// Check for the file existing first
if (!File.Exists(this.Filename))
if (this.Filename == null || !File.Exists(this.Filename))
return null;
string datum = Path.GetFileName(this.Filename).ToLowerInvariant();