mirror of
https://github.com/ppy/osu.git
synced 2024-11-11 12:57:36 +08:00
Fix SkinManager not handling extensions casing comparsion properly
This commit is contained in:
parent
6a37fb41cc
commit
fc5719e445
@ -104,7 +104,7 @@ namespace osu.Game.Skinning
|
||||
protected override string ComputeHash(SkinInfo item, ArchiveReader reader = null)
|
||||
{
|
||||
// we need to populate early to create a hash based off skin.ini contents
|
||||
if (item.Name?.Contains(".osk") == true)
|
||||
if (item.Name?.EndsWith(".osk", StringComparison.OrdinalIgnoreCase) == true)
|
||||
populateMetadata(item);
|
||||
|
||||
if (item.Creator != null && item.Creator != unknown_creator_string)
|
||||
@ -122,7 +122,7 @@ namespace osu.Game.Skinning
|
||||
{
|
||||
await base.Populate(model, archive, cancellationToken).ConfigureAwait(false);
|
||||
|
||||
if (model.Name?.Contains(".osk") == true)
|
||||
if (model.Name?.EndsWith(".osk", StringComparison.OrdinalIgnoreCase) == true)
|
||||
populateMetadata(model);
|
||||
}
|
||||
|
||||
@ -137,7 +137,7 @@ namespace osu.Game.Skinning
|
||||
}
|
||||
else
|
||||
{
|
||||
item.Name = item.Name.Replace(".osk", "");
|
||||
item.Name = item.Name.Replace(".osk", "", StringComparison.OrdinalIgnoreCase);
|
||||
item.Creator ??= unknown_creator_string;
|
||||
}
|
||||
}
|
||||
|
Loading…
Reference in New Issue
Block a user