Преглед на файлове

Fixed user profile path for config loading

Lukas Angerer преди 1 година
родител
ревизия
baacc47d64
променени са 1 файла, в които са добавени 1 реда и са изтрити 1 реда
  1. 1 1
      WebTemplate/AppServer.cs

+ 1 - 1
WebTemplate/AppServer.cs

@@ -61,6 +61,6 @@ public class AppServer
 
     private void SetupConfiguration(ConfigurationManager configuration, IWebHostEnvironment env)
     {
-        configuration.AddJsonFile($"~/{env.ApplicationName}.json", optional: true);
+        configuration.AddJsonFile($"{Environment.GetFolderPath(Environment.SpecialFolder.UserProfile)}/{env.ApplicationName}.json", optional: true);
     }
 }