Skip to content

Commit

Permalink
Browse files Browse the repository at this point in the history
  • Loading branch information
gboissinot committed Feb 19, 2012
1 parent 0f9ab22 commit 3f3ef65
Showing 1 changed file with 3 additions and 3 deletions.
Expand Up @@ -38,8 +38,8 @@ public Map<String, String> getVarsFromPropertiesFile(File propertiesFile, Map<St
SortedProperties properties = new SortedProperties();
try {
String fileContent = Util.loadFile(propertiesFile);
fileContent = processFilePath(fileContent);
String fileContentResolved = Util.replaceMacro(fileContent, currentEnvVars);
fileContentResolved = processPath(fileContentResolved);
properties.load(new StringReader(fileContentResolved));
} catch (IOException ioe) {
throw new EnvInjectException("Problem occurs on loading content", ioe);
Expand Down Expand Up @@ -67,7 +67,7 @@ public Map<String, String> getVarsFromPropertiesContent(String content) throws E
return null;
}

content = processFilePath(content);
content = processPath(content);

Map<String, String> result = new LinkedHashMap<String, String>();
StringReader stringReader = new StringReader(content);
Expand All @@ -93,7 +93,7 @@ private String processProperty(Object prop) {
return String.valueOf(prop).trim();
}

private String processFilePath(String content) {
private String processPath(String content) {
if (content == null) {
return null;
}
Expand Down

0 comments on commit 3f3ef65

Please sign in to comment.