Skip to content
Snippets Groups Projects
Commit 2068a099 authored by Robert Goldmann's avatar Robert Goldmann
Browse files

Fixed #374 - missing settings file warning format

parent 1b98f016
No related branches found
No related tags found
No related merge requests found
...@@ -59,7 +59,7 @@ public class Main implements ApplicationRunner ...@@ -59,7 +59,7 @@ public class Main implements ApplicationRunner
{ {
try try
{ {
LOGGER.warn("BudgetMaster settings file ({0}) is missing. A default file will be created. Please fill in your settings.", settingsPath); LOGGER.warn("BudgetMaster settings file ({}) is missing. A default file will be created. Please fill in your settings.", settingsPath);
Files.copy(Main.class.getClassLoader().getResourceAsStream("config/templates/settings.properties"), settingsPath, StandardCopyOption.REPLACE_EXISTING); Files.copy(Main.class.getClassLoader().getResourceAsStream("config/templates/settings.properties"), settingsPath, StandardCopyOption.REPLACE_EXISTING);
System.exit(1); System.exit(1);
} }
......
...@@ -13,7 +13,8 @@ import java.nio.file.Path; ...@@ -13,7 +13,8 @@ import java.nio.file.Path;
public class PropertiesConfiguration public class PropertiesConfiguration
{ {
@Bean @Bean
public PropertySourcesPlaceholderConfigurer propertySourcesPlaceholderConfigurer() { public PropertySourcesPlaceholderConfigurer propertySourcesPlaceholderConfigurer()
{
PropertySourcesPlaceholderConfigurer properties = new PropertySourcesPlaceholderConfigurer(); PropertySourcesPlaceholderConfigurer properties = new PropertySourcesPlaceholderConfigurer();
Path settingsPath = SystemUtils.getApplicationSupportDirectoryPath(Localization.getString("folder"), "settings.properties"); Path settingsPath = SystemUtils.getApplicationSupportDirectoryPath(Localization.getString("folder"), "settings.properties");
properties.setLocation(new FileSystemResource(settingsPath.toString())); properties.setLocation(new FileSystemResource(settingsPath.toString()));
......
0% Loading or .
You are about to add 0 people to the discussion. Proceed with caution.
Please register or to comment