src/main/java/dev/gardeningtool/namemc/web/RequestUtil.java
@SneakyThrows
    public static boolean optifineCape(String username) {
        URL url = new URL(String.format("http://s.optifine.net/capes/%s.png", username));
        HttpURLConnection connection = (HttpURLConnection) url.openConnection();
        return connection.getResponseCode() != 404;
    }
/**
     * @param username The target username
     * @return Whether or not the player has an OptiFine cape
     */
@param username The target username
@return Whether or not the player has an OptiFine cape
@param username The target username @return Whether or not the player has an OptiFine cape
@SneakyThrows
    public static boolean optifineCape(String username) {
        URL url = new URL(String.format("http://s.optifine.net/capes/%s.png", username));
        HttpURLConnection connection = (HttpURLConnection) url.openConnection();
        return connection.getResponseCode() != 404;
    }
@ SneakyThrows public static boolean optifineCape ( String username ) { URL url = new URL ( String . format ( "http://s.optifine.net/capes/%s.png" , username ) ) ; HttpURLConnection connection = ( HttpURLConnection ) url . openConnection ( ) ; return connection . getResponseCode ( ) != 404 ; }
@param username The target username
 @return Whether or not the player has an OptiFine cape
@param username The target username @return Whether or not the player has an OptiFine cape