summaryrefslogtreecommitdiff
path: root/app/src/release/java
diff options
context:
space:
mode:
authorParménides GV <parmegv@sdf.org>2015-04-15 10:41:59 +0200
committerParménides GV <parmegv@sdf.org>2015-04-15 10:42:34 +0200
commitc8994b645b607723bdaba4c2aa1ff0d19a9c0c13 (patch)
tree942129a0870fce168fcb788fa5d7ec21b7fae5bc /app/src/release/java
parente522e5e325e6ed19b1316fd251f3c212a2344d7c (diff)
Set accept-language in ProviderAPI, language-country
String locale = Locale.getDefault().getLanguage() + Locale.getDefault().getCountry();
Diffstat (limited to 'app/src/release/java')
-rw-r--r--app/src/release/java/se/leap/bitmaskclient/ProviderAPI.java2
1 files changed, 2 insertions, 0 deletions
diff --git a/app/src/release/java/se/leap/bitmaskclient/ProviderAPI.java b/app/src/release/java/se/leap/bitmaskclient/ProviderAPI.java
index 24e7df20..890262ce 100644
--- a/app/src/release/java/se/leap/bitmaskclient/ProviderAPI.java
+++ b/app/src/release/java/se/leap/bitmaskclient/ProviderAPI.java
@@ -416,6 +416,8 @@ public class ProviderAPI extends IntentService {
InputStream is = null;
urlConnection = (HttpsURLConnection) new URL(url).openConnection();
urlConnection.setRequestMethod(request_method);
+ String locale = Locale.getDefault().getLanguage() + Locale.getDefault().getCountry();
+ urlConnection.setRequestProperty("Accept-Language", locale);
urlConnection.setChunkedStreamingMode(0);
urlConnection.setSSLSocketFactory(getProviderSSLSocketFactory());