Remove unnecessary input stream
authorDavid ‘Bombe’ Roden <bombe@pterodactylus.net>
Sat, 9 May 2015 08:15:55 +0000 (10:15 +0200)
committerDavid ‘Bombe’ Roden <bombe@pterodactylus.net>
Sat, 9 May 2015 08:17:22 +0000 (10:17 +0200)
src/main/java/net/pterodactylus/rhynodge/queries/HttpQuery.java

index 362a04b..3d28590 100644 (file)
@@ -74,7 +74,6 @@ public class HttpQuery implements Query {
                                .addInterceptorFirst(new ResponseContentEncoding()).build();
                HttpGet get = new HttpGet(uri);
 
-               InputStreamReader inputStreamReader = null;
                try {
                        /* make request. */
                        get.addHeader("User-Agent", "Mozilla/5.0 (X11; Linux x86_64) AppleWebKit/536.11 (KHTML, like Gecko) Ubuntu/12.04 Chromium/20.0.1132.47 Chrome/20.0.1132.47 Safari/536.11");
@@ -91,8 +90,6 @@ public class HttpQuery implements Query {
 
                } catch (IOException ioe1) {
                        return new FailedState(ioe1);
-               } finally {
-                       Closeables.closeQuietly(inputStreamReader);
                }
        }