Update unhandled_email.py

This commit is contained in:
Aditya Hase 2019-10-21 21:00:13 +05:30
parent 83c10c9263
commit cef8f4d450
No known key found for this signature in database
GPG key ID: 2F5E3D5822BBF831

View file

@ -11,4 +11,4 @@ class UnhandledEmail(Document):
def remove_old_unhandled_emails():
frappe.db.sql("""DELETE FROM `tabUnhandled Email` WHERE datediff(curdate(), date(creation)) > 30""")
frappe.db.sql("""DELETE FROM `tabUnhandled Email` WHERE DATEDIFF(CURRENT_DATE(), DATE(creation)) > 30""")