Merge branch 'NullExceptions' into 'dev'

Fixed Null Exception

See merge request morningstar/Arcturus-Community!277
This commit is contained in:
Harmonic 2020-09-19 13:16:50 -04:00
commit 114794c171

View File

@ -23,7 +23,7 @@ public class ConfigurationManager {
public boolean loaded = false;
public boolean isLoading = false;
public ConfigurationManager(String configurationPath) throws Exception {
public ConfigurationManager(String configurationPath) {
this.properties = new Properties();
this.configurationPath = configurationPath;
this.reload();
@ -37,7 +37,12 @@ public class ConfigurationManager {
String envDbHostname = System.getenv("DB_HOSTNAME");
boolean useEnvVarsForDbConnection = envDbHostname != null && envDbHostname.length() > 1;
boolean useEnvVarsForDbConnection = false;
if(envDbHostname != null)
{
useEnvVarsForDbConnection = envDbHostname.length() > 1;
}
if (!useEnvVarsForDbConnection) {
try {