fix: Fixes UOClient NPE (#952)
This commit is contained in:
parent
5a43c806fe
commit
1f4162288e
1 changed files with 12 additions and 11 deletions
|
|
@ -46,20 +46,21 @@ public static class UOClient
|
|||
{
|
||||
if (ServerClientVersion == null)
|
||||
{
|
||||
logger.Warning("Could not detect client version.");
|
||||
logger.Warning("Could not detect client version. This may cause data files to load improperly.");
|
||||
return;
|
||||
}
|
||||
else if (CuoSettings.ClientVersion == ServerClientVersion)
|
||||
|
||||
if (_automaticallyDetected)
|
||||
{
|
||||
logger.Information($"Automatically detected client version {ServerClientVersion} from CUO settings.");
|
||||
}
|
||||
else if (_automaticallyDetected)
|
||||
{
|
||||
logger.Information($"Automatically detected client version {ServerClientVersion}");
|
||||
}
|
||||
else
|
||||
{
|
||||
logger.Information($"Manually configured to use client version {ServerClientVersion}");
|
||||
logger.Information(
|
||||
CuoSettings?.ClientVersion == ServerClientVersion
|
||||
? $"Automatically detected client version {ServerClientVersion} from CUO settings."
|
||||
: $"Automatically detected client version {ServerClientVersion}"
|
||||
);
|
||||
return;
|
||||
}
|
||||
|
||||
logger.Information($"Manually configured to use client version {ServerClientVersion}");
|
||||
}
|
||||
|
||||
private static ClientVersion DetectCUOClient()
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue