1
0
mirror of https://github.com/ppy/osu.git synced 2024-09-22 00:47:24 +08:00

Fix LegacyFilesystemReader Filenames property.

This commit is contained in:
Damnae 2017-09-18 10:14:29 +02:00
parent 407d02ba87
commit 5a76ed4000

View File

@ -1,6 +1,7 @@
// Copyright (c) 2007-2017 ppy Pty Ltd <contact@ppy.sh>.
// Licensed under the MIT Licence - https://raw.githubusercontent.com/ppy/osu/master/LICENCE
using osu.Framework.IO.File;
using System.Collections.Generic;
using System.IO;
using System.Linq;
@ -26,7 +27,7 @@ namespace osu.Game.Beatmaps.IO
// no-op
}
public override IEnumerable<string> Filenames => Directory.GetFiles(path, "*", SearchOption.AllDirectories).Select(Path.GetFileName).ToArray();
public override IEnumerable<string> Filenames => Directory.GetFiles(path, "*", SearchOption.AllDirectories).Select(f => FileSafety.GetRelativePath(f, path)).ToArray();
public override Stream GetUnderlyingStream() => null;
}