Allow hash type on GenerateHash and remove obsoleted ToMd5 and ToSHA1 methods (#6679)

This commit is contained in:
Ronald Barendse
2019-10-23 17:19:49 +02:00
committed by Sebastiaan Janssen
parent e3bc30c4ca
commit d0303f74fd
5 changed files with 37 additions and 46 deletions

View File

@@ -67,7 +67,7 @@ namespace Umbraco.Core.Models
if (user.Avatar.IsNullOrWhiteSpace())
{
var gravatarHash = user.Email.ToMd5();
var gravatarHash = user.Email.GenerateHash<MD5>();
var gravatarUrl = "https://www.gravatar.com/avatar/" + gravatarHash + "?d=404";
//try Gravatar