Mark User.gravatar() as deprecated
We're using self-hosted avatars instead. See `pillar.api.users.avatar.url()` in the Pillar source code instead.
This commit is contained in:
@@ -14,7 +14,12 @@ class User(List, Find, Create, Post, Update, Delete):
|
||||
path = "users"
|
||||
|
||||
def gravatar(self, size=64):
|
||||
"""Generate Gravatar link on the fly using the email value"""
|
||||
"""Deprecated: return the Gravatar URL.
|
||||
|
||||
.. deprecated::
|
||||
Use of Gravatar is deprecated, in favour of our self-hosted avatars.
|
||||
See pillar.api.users.avatar.url(user).
|
||||
"""
|
||||
parameters = {'s':str(size), 'd':'mm'}
|
||||
return "https://www.gravatar.com/avatar/" + \
|
||||
hashlib.md5(self.email.lower()).hexdigest() + \
|
||||
|
||||
Reference in New Issue
Block a user