You are viewing a plain text version of this content. The canonical link for it is here.
Posted to commits@ponymail.apache.org by hu...@apache.org on 2021/09/07 21:28:05 UTC
[incubator-ponymail-foal] 02/02: only generate gravatar if not
found.
This is an automated email from the ASF dual-hosted git repository.
humbedooh pushed a commit to branch master
in repository https://gitbox.apache.org/repos/asf/incubator-ponymail-foal.git
commit 3e579be19046844d42e9356a8a28ce28870211e3
Author: Daniel Gruno <hu...@apache.org>
AuthorDate: Tue Sep 7 16:27:53 2021 -0500
only generate gravatar if not found.
---
server/endpoints/email.py | 3 ++-
1 file changed, 2 insertions(+), 1 deletion(-)
diff --git a/server/endpoints/email.py b/server/endpoints/email.py
index 1a55521..0e8e6dd 100644
--- a/server/endpoints/email.py
+++ b/server/endpoints/email.py
@@ -44,7 +44,8 @@ async def process(
if plugins.aaa.can_access_email(session, email):
# Are we fetching an attachment?
if not indata.get("attachment"):
- email["gravatar"] = plugins.messages.gravatar(email)
+ if not email.get("gravatar"):
+ email["gravatar"] = plugins.messages.gravatar(email)
return email
else:
fid = indata.get("file")