8000 using System.getProperty instead of System.getProperties().getProperty · Geisirc/google-http-java-client@d04ea32 · GitHub
[go: up one dir, main page]

Skip to content

Commit d04ea32

Browse files
Daniel Ribeiromattwhisenhunt
authored andcommitted
using System.getProperty instead of System.getProperties().getProperty
1 parent ea47b63 commit d04ea32

File tree

1 file changed

+4
-4
lines changed

1 file changed

+4
-4
lines changed

google-http-client/src/main/java/com/google/api/client/http/javanet/NetHttpTransport.java

Lines changed: 4 additions & 4 deletions
Original file line numberDiff line numberDiff line change
@@ -62,8 +62,8 @@ public final class NetHttpTransport extends HttpTransport {
6262
private static Proxy defaultProxy() {
6363
return new Proxy(
6464
Proxy.Type.HTTP, new InetSocketAddress(
65-
System.getProperties().getProperty("https.proxyHost"),
66-
Integer.parseInt(System.getProperties().getProperty("https.proxyPort"))));
65+
System.getProperty("https.proxyHost"),
66+
Integer.parseInt(System.getProperty("https.proxyPort"))));
6767
}
6868

6969
/**
@@ -130,7 +130,7 @@ public NetHttpTransport() {
130130

131131
private ConnectionFactory getConnectionFactory(ConnectionFactory connectionFactory) {
132132
if (connectionFactory == null) {
133-
if (System.getProperties().getProperty("com.google.api.client.should_use_proxy") != null) {
133+
if (System.getProperty("com.api.client.should_use_proxy") != null) {
134134
return new DefaultConnectionFactory(defaultProxy());
135135
}
136136
return new DefaultConnectionFactory();
@@ -329,7 +329,7 @@ public Builder setHostnameVerifier(HostnameVerifier hostnameVerifier) {
329329

330330
/** Returns a new instance of {@link NetHttpTransport} based on the options. */
331331
public NetHttpTransport build() {
332-
if (System.getProperties().getProperty("com.google.api.client.should_use_proxy") != null) {
332+
if (System.getProperty("com.google.api.client.should_use_proxy") != null) {
333333
setProxy(defaultProxy());
334334
}
335335
return this.proxy == null

0 commit comments

Comments
 (0)
0