@@ -24,7 +24,7 @@ public static String fixAvatar(final String imageUrl, int avatarSz) {
2424 return getPhotonImageUrl (imageUrl , avatarSz , avatarSz );
2525
2626 // remove all other params, then add query string for size and "mystery man" default
27- return UrlUtils .removeQuery (imageUrl ) + String . format ( "?s=%d &d=mm" , avatarSz ) ;
27+ return UrlUtils .removeQuery (imageUrl ) + "?s=" + avatarSz + " &d=mm" ;
2828 }
2929
3030 /*
@@ -64,18 +64,18 @@ public static String getPhotonImageUrl(String imageUrl, int width, int height) {
6464 // see http://wp.tutsplus.com/tutorials/how-to-generate-website-screenshots-for-your-wordpress-site/
6565 // ex: http://s.wordpress.com/mshots/v1/http%3A%2F%2Fnickbradbury.com?w=600
6666 if (isMshotsUrl (imageUrl )) {
67- return imageUrl + String . format ( "?w=%d &h=%d" , width , height ) ;
67+ return imageUrl + "?w=" + width + " &h=" + height ;
6868 }
6969
7070 // if both width & height are passed use the "resize" param, use only "w" or "h" if just
7171 // one of them is set, otherwise no query string
7272 final String query ;
7373 if (width > 0 && height > 0 ) {
74- query = String . format ( "?resize=%d,%d" , width , height ) ;
74+ query = "?resize=" + width + "," + height ;
7575 } else if (width > 0 ) {
76- query = String . format ( "?w=%d" , width ) ;
76+ query = "?w=" + width ;
7777 } else if (height > 0 ) {
78- query = String . format ( "?h=%d" , height ) ;
78+ query = "?h=" + height ;
7979 } else {
8080 query = "" ;
8181 }
0 commit comments