1
0
mirror of https://github.com/SKCraft/Launcher.git synced 2025-01-08 19:38:58 +01:00

Set a user agent for HTTP requests

It is now "Mozilla/5.0 (Java) SKMCLauncher"
This commit is contained in:
Albert Pham 2014-02-17 19:02:45 -08:00
parent 234d312423
commit fd506bda61

View File

@ -109,6 +109,7 @@ public class HttpRequest implements Closeable, ProgressObservable {
}
conn = (HttpURLConnection) reformat(url).openConnection();
conn.setRequestProperty("User-Agent", "Mozilla/5.0 (Java) SKMCLauncher");
if (body != null) {
conn.setRequestProperty("Content-Type", contentType);