Skip to content

Commit 3d0b9a3

Browse files
pirhoobamthomas
authored andcommitted
refactor: remove nonnecessary getenv wrapper method
1 parent 0073aad commit 3d0b9a3

File tree

1 file changed

+2
-8
lines changed
  • src/main/java/net/codestory/http/misc

1 file changed

+2
-8
lines changed

src/main/java/net/codestory/http/misc/Env.java

Lines changed: 2 additions & 8 deletions
Original file line numberDiff line numberDiff line change
@@ -15,7 +15,6 @@
1515
*/
1616
package net.codestory.http.misc;
1717

18-
import com.google.common.annotations.VisibleForTesting;
1918
import net.codestory.http.reload.MasterFolderWatch;
2019

2120
import java.io.File;
@@ -173,18 +172,13 @@ public boolean diskCache() {
173172
return diskCache;
174173
}
175174

176-
@VisibleForTesting
177-
private static String getenv(String envVar) {
178-
return System.getenv(envVar);
179-
}
180-
181175
private static String get(String propertyName) {
182-
String env = getenv(propertyName);
176+
String env = System.getenv(propertyName);
183177
return (env != null) ? env : System.getProperty(propertyName);
184178
}
185179

186180
private static String get(String propertyName, String defaultValue) {
187-
String env = getenv(propertyName);
181+
String env = System.getenv(propertyName);
188182
return (env != null) ? env : System.getProperty(propertyName, defaultValue);
189183
}
190184

0 commit comments

Comments
 (0)