static String formatUrl(String url) { if (url[url.length - 1] == "/") return url.substring(0, url.length - 1); return url; }