mirror of
https://github.com/HMCL-dev/HMCL.git
synced 2025-01-30 14:39:56 +08:00
feat: send accept language header
This commit is contained in:
parent
7c510f9fb8
commit
e6d11fe9a3
@ -20,6 +20,7 @@ package org.jackhuang.hmcl.util.io;
|
||||
import java.io.*;
|
||||
import java.net.*;
|
||||
import java.util.List;
|
||||
import java.util.Locale;
|
||||
import java.util.Map;
|
||||
import java.util.Map.Entry;
|
||||
|
||||
@ -59,6 +60,7 @@ public final class NetworkUtils {
|
||||
connection.setUseCaches(false);
|
||||
connection.setConnectTimeout(15000);
|
||||
connection.setReadTimeout(15000);
|
||||
connection.setRequestProperty("Accept-Language", Locale.getDefault().toString());
|
||||
return connection;
|
||||
}
|
||||
|
||||
|
Loading…
Reference in New Issue
Block a user