Skip to content

Commit

Permalink
Merge branch 'develop' into feature/site-settings-review
Browse files Browse the repository at this point in the history
Conflicts:
	WordPress/src/main/res/values/colors.xml
  • Loading branch information
tonyr59h committed Nov 10, 2015
2 parents def84af + 20a169b commit 1b1e118
Showing 1 changed file with 6 additions and 0 deletions.
Original file line number Diff line number Diff line change
Expand Up @@ -88,6 +88,12 @@ public static String getPhotonImageUrl(String imageUrl, int width, int height, Q
return imageUrl + query;
}

// use wordpress.com as the host if image is on wordpress.com since it supports the same
// query params and, more importantly, can handle images in private blogs
if (imageUrl.contains("wordpress.com")) {
return imageUrl + query;
}

// must use https for https image urls
if (UrlUtils.isHttps(imageUrl)) {
return "https://i0.wp.com/" + imageUrl.substring(schemePos+3, imageUrl.length()) + query;
Expand Down

0 comments on commit 1b1e118

Please sign in to comment.