'If email limit is set, don\'t allow users to delete Email Queue record'

def prevent_email_queue_delete(self):

    if (get_limits().emails and (frappe.session.user != u'Administrator')):
        frappe.throw(_(u'Only    Administrator    can    delete    Email    Queue'))
