From 8d034ecc231451daa7fdb1284128fc3cec177187 Mon Sep 17 00:00:00 2001 From: Jamy Mahabier Date: Wed, 2 Nov 2016 20:44:55 +0100 Subject: [PATCH] Add version number to user agent --- src/main/java/org/drtshock/Potato.java | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/src/main/java/org/drtshock/Potato.java b/src/main/java/org/drtshock/Potato.java index cb43896..fbe939e 100644 --- a/src/main/java/org/drtshock/Potato.java +++ b/src/main/java/org/drtshock/Potato.java @@ -80,7 +80,7 @@ public class Potato implements Tuber { final URL url = new URL("https://www.google.com/search?q=potato"); HttpURLConnection connection = (HttpURLConnection) url.openConnection(); connection.setRequestMethod("GET"); - connection.addRequestProperty("User-Agent", "Potato"); + connection.addRequestProperty("User-Agent", "Potato/1.7.5"); connection.connect(); int inOven = connection.getResponseCode(); return inOven == 200;