diff --git a/frappe/__init__.py b/frappe/__init__.py index 6e3f06807f..68c9a0270e 100644 --- a/frappe/__init__.py +++ b/frappe/__init__.py @@ -13,7 +13,7 @@ import os, sys, importlib, inspect, json from .exceptions import * from .utils.jinja import get_jenv, get_template, render_template -__version__ = '8.0.27' +__version__ = '8.0.28' __title__ = "Frappe Framework" local = Local() diff --git a/frappe/email/doctype/email_account/email_account.py b/frappe/email/doctype/email_account/email_account.py index 8f56f2a435..70fbae6efe 100755 --- a/frappe/email/doctype/email_account/email_account.py +++ b/frappe/email/doctype/email_account/email_account.py @@ -251,8 +251,10 @@ class EmailAccount(Document): return emails = email_server.get_messages() + if not emails: + return - incoming_mails = emails.get("latest_messages") + incoming_mails = emails.get("latest_messages", []) uid_list = emails.get("uid_list", []) seen_status = emails.get("seen_status", []) uid_reindexed = emails.get("uid_reindexed", False) diff --git a/frappe/email/receive.py b/frappe/email/receive.py index 750ad865a9..1916bcd5ef 100644 --- a/frappe/email/receive.py +++ b/frappe/email/receive.py @@ -100,7 +100,7 @@ class EmailServer: frappe.db.commit() if not self.connect(): - return [] + return uid_list = []