use string.EndsWith() method instead of Path.GetExtension()

This commit is contained in:
morkt
2015-05-15 18:49:37 +04:00
parent 8640e34c27
commit a2051e6752
6 changed files with 6 additions and 9 deletions

View File

@@ -296,8 +296,7 @@ namespace GameRes.Formats.ONScripter
var header_entry = new NsaEntry { Name = entry.Name };
if (Compression.None != ons_options.CompressionType)
{
string ext = Path.GetExtension (entry.Name).ToLower();
if (".bmp" == ext)
if (entry.Name.EndsWith (".bmp", StringComparison.InvariantCultureIgnoreCase))
header_entry.CompressionType = ons_options.CompressionType;
}
index_size += 13;