mirror of
https://github.com/ppy/osu
synced 2025-03-21 10:28:06 +00:00
Fix import not working
This commit is contained in:
parent
4dfb63023f
commit
767c284793
@ -412,7 +412,7 @@ namespace osu.Game.Database
|
|||||||
private ArchiveReader getReaderFrom(string path)
|
private ArchiveReader getReaderFrom(string path)
|
||||||
{
|
{
|
||||||
if (ZipUtils.IsZipArchive(path))
|
if (ZipUtils.IsZipArchive(path))
|
||||||
return new ZipArchiveReader(Files.Storage.GetStream(path), Path.GetFileName(path));
|
return new ZipArchiveReader(File.Open(path, FileMode.Open, FileAccess.Read, FileShare.Read), Path.GetFileName(path));
|
||||||
if (Directory.Exists(path))
|
if (Directory.Exists(path))
|
||||||
return new LegacyFilesystemReader(path);
|
return new LegacyFilesystemReader(path);
|
||||||
throw new InvalidFormatException($"{path} is not a valid archive");
|
throw new InvalidFormatException($"{path} is not a valid archive");
|
||||||
|
Loading…
Reference in New Issue
Block a user