use HasExtension method instead of string.EndsWith.

This commit is contained in:
morkt
2017-04-10 23:15:13 +04:00
parent e0a5e95081
commit 31a01f2e5d
72 changed files with 105 additions and 114 deletions

View File

@@ -94,7 +94,7 @@ namespace GameRes.Formats.Rpm
return null;
var scheme = GuessScheme (file, count);
// additional filename extension check avoids dialog popup on false positives
if (null == scheme && KnownSchemes.Count > 0 && file.Name.EndsWith (".arc", StringComparison.InvariantCultureIgnoreCase))
if (null == scheme && KnownSchemes.Count > 0 && file.Name.HasExtension (".arc"))
scheme = QueryScheme();
if (null == scheme)
return null;