Skip to content

Commit

Permalink
Browse files Browse the repository at this point in the history
environment variables should be underscore separated.
  • Loading branch information
yusuke committed Oct 20, 2022
1 parent 9c26f9f commit 3263f18
Showing 1 changed file with 4 additions and 1 deletion.
Original file line number Diff line number Diff line change
Expand Up @@ -87,7 +87,10 @@ static void loadDefaultProperties(Configuration conf) {
try {
Map<String, String> envMap = System.getenv();
for (String key : envMap.keySet()) {
props.setProperty(key, envMap.get(key));
if (key.startsWith("twitter4j_")) {
String t4jKey = key.substring(key.indexOf("_")+1).replaceAll("_", ".");
props.setProperty(t4jKey, envMap.get(key));
}
}
} catch (SecurityException ignore) {
}
Expand Down

0 comments on commit 3263f18

Please sign in to comment.