imageUrl method

String imageUrl({
  1. int size = 80,
  2. String defaultImage = "identicon",
  3. String rating = "g",
})

generate ImageUrl for Gravatar

Implementation

String imageUrl(
    {int size = 80, String defaultImage = "identicon", String rating = "g"}) {
  String _imageUrl = _gravatarUrl + "avatar/" + _generateMd5(_email);

  _imageUrl += "?" + "s=" + size.toString();
  _imageUrl += "&" + "r=" + rating;
  _imageUrl += "&" + "d=" + defaultImage;

  return _imageUrl;
}