just a small fix that I forgot to include in the last build.

This commit is contained in:
RaidMax 2020-02-03 08:21:42 -06:00
parent 2872d02c37
commit 15e2170100

View File

@ -68,15 +68,15 @@ namespace IW4MAdmin.Application
ITranslationLookup translationLookup = null; ITranslationLookup translationLookup = null;
try try
{ {
// do any needed housekeeping file/folder migrations
ConfigurationMigration.MoveConfigFolder10518(null);
ConfigurationMigration.CheckDirectories();
var services = ConfigureServices(); var services = ConfigureServices();
serviceProvider = services.BuildServiceProvider(); serviceProvider = services.BuildServiceProvider();
ServerManager = (ApplicationManager)serviceProvider.GetRequiredService<IManager>(); ServerManager = (ApplicationManager)serviceProvider.GetRequiredService<IManager>();
translationLookup = serviceProvider.GetRequiredService<ITranslationLookup>(); translationLookup = serviceProvider.GetRequiredService<ITranslationLookup>();
// do any needed housekeeping file/folder migrations
ConfigurationMigration.MoveConfigFolder10518(null);
ConfigurationMigration.CheckDirectories();
ServerManager.Logger.WriteInfo(Utilities.CurrentLocalization.LocalizationIndex["MANAGER_VERSION"].FormatExt(Version)); ServerManager.Logger.WriteInfo(Utilities.CurrentLocalization.LocalizationIndex["MANAGER_VERSION"].FormatExt(Version));
await CheckVersion(translationLookup); await CheckVersion(translationLookup);
@ -97,7 +97,10 @@ namespace IW4MAdmin.Application
if (e is ConfigurationException configException) if (e is ConfigurationException configException)
{ {
Console.WriteLine(translationLookup[configException.Message].FormatExt(configException.ConfigurationFileName)); if (translationLookup != null)
{
Console.WriteLine(translationLookup[configException.Message].FormatExt(configException.ConfigurationFileName));
}
foreach (string error in configException.Errors) foreach (string error in configException.Errors)
{ {