1
0
mirror of https://github.com/ppy/osu.git synced 2024-11-11 09:27:29 +08:00

Force a read of the location file during detection

This commit is contained in:
Shivam 2020-05-17 22:27:44 +02:00
parent 80d188ec91
commit 4bc858a215

View File

@ -232,15 +232,17 @@ namespace osu.Game.Tournament.IPC
private string findFromJsonConfig()
{
try
Logger.Log("Trying to find stable through the json config");
if (tournamentStorage.Exists(stable_config))
{
Logger.Log("Trying to find stable through the json config");
return stableInfo.StablePath.Value;
using (Stream stream = tournamentStorage.GetStream(stable_config, FileAccess.Read, FileMode.Open))
using (var sr = new StreamReader(stream))
{
stableInfo = JsonConvert.DeserializeObject<StableInfo>(sr.ReadToEnd());
return stableInfo.StablePath.Value;
}
}
catch
{
}
return null;
}