mirror of
https://github.com/ppy/osu.git
synced 2024-12-14 19:22:54 +08:00
Merge pull request #19096 from peppy/custom-storage-log-output
Add log output for custom storage usage
This commit is contained in:
commit
7f59426587
@ -94,6 +94,8 @@ namespace osu.Game.IO
|
||||
error = OsuStorageError.None;
|
||||
Storage lastStorage = UnderlyingStorage;
|
||||
|
||||
Logger.Log($"Attempting to use custom storage location {CustomStoragePath}");
|
||||
|
||||
try
|
||||
{
|
||||
Storage userStorage = host.GetStorage(CustomStoragePath);
|
||||
@ -102,6 +104,7 @@ namespace osu.Game.IO
|
||||
error = OsuStorageError.AccessibleButEmpty;
|
||||
|
||||
ChangeTargetStorage(userStorage);
|
||||
Logger.Log($"Storage successfully changed to {CustomStoragePath}.");
|
||||
}
|
||||
catch
|
||||
{
|
||||
@ -109,6 +112,9 @@ namespace osu.Game.IO
|
||||
ChangeTargetStorage(lastStorage);
|
||||
}
|
||||
|
||||
if (error != OsuStorageError.None)
|
||||
Logger.Log($"Custom storage location could not be used ({error}).");
|
||||
|
||||
return error == OsuStorageError.None;
|
||||
}
|
||||
|
||||
|
Loading…
Reference in New Issue
Block a user