human
I wrote the below code

    def add_user_email(user):
        user = frappe.get_doc(u'User', user)
        row = user.append(u'user_emails', {})
        row.email_id = email_id
        row.email_account = email_account
        row.awaiting_password = (awaiting_password or 0)
        row.enable_outgoing = (enable_outgoing or 0)
        user.save(ignore_permissions=True)
    udpate_user_email_settings = False
    if (not all([email_account, email_id])):
        return
    user_names = frappe.db.get_values(u'User', {u'email': email_id}, as_dict=True)
    if (not user_names):
        return
    for user in user_names:
        user_name = user.get(u'name')
        user_inbox = (frappe.db.get_value(u'User    Email', {u'email_account': email_account, u'parent': user_name}, [u'name']) or None)
        if (not user_inbox):
            add_user_email(user_name)
        else:
            udpate_user_email_settings = True
    if udpate_user_email_settings:
        frappe.db.sql(u'UPDATE    `tabUser    Email`    SET    awaiting_password    =    %(awaiting_password)s,\n DCTB  DCTB  DCTB enable_outgoing    =    %(enable_outgoing)s    WHERE    email_account    =    %(email_account)s', {u'email_account': email_account, u'enable_outgoing': enable_outgoing, u'awaiting_password': (awaiting_password or 0)})
    else:
        frappe.msgprint(_(u'Enabled    email    inbox    for    user    {users}'.format(users=u'    and    '.join([frappe.bold(user.get(u'name')) for user in user_names]))))
    ask_pass_update()

What's a good function header?

=====
Here's a good function header?
assistant
#Here's a good function header.

def setup_user_email_inbox(email_account, awaiting_password, email_id, enable_outgoing):