diff --git a/frappe/__init__.py b/frappe/__init__.py index 2000313906..8744c3aaf0 100644 --- a/frappe/__init__.py +++ b/frappe/__init__.py @@ -14,7 +14,7 @@ import os, sys, importlib, inspect, json from .exceptions import * from .utils.jinja import get_jenv, get_template, render_template, get_email_from_template -__version__ = '10.1.35' +__version__ = '10.1.36' __title__ = "Frappe Framework" local = Local() diff --git a/frappe/email/smtp.py b/frappe/email/smtp.py index 62d0dce95b..f0d0d2a820 100644 --- a/frappe/email/smtp.py +++ b/frappe/email/smtp.py @@ -54,7 +54,23 @@ def get_outgoing_email_account(raise_exception_not_set=True, append_to=None, sen if append_to: # append_to is only valid when enable_incoming is checked - email_account = _get_email_account({"enable_outgoing": 1, "enable_incoming": 1, "append_to": append_to}) + + # in case of multiple Email Accounts with same append_to + # narrow it down based on email_id + email_account = _get_email_account({ + "enable_outgoing": 1, + "enable_incoming": 1, + "append_to": append_to, + "email_id": sender_email_id + }) + + # else find the first Email Account with append_to + if not email_account: + email_account = _get_email_account({ + "enable_outgoing": 1, + "enable_incoming": 1, + "append_to": append_to + }) if not email_account and sender_email_id: # check if the sender has email account with enable_outgoing diff --git a/package.json b/package.json index 5f9f50162c..f7634be926 100644 --- a/package.json +++ b/package.json @@ -28,7 +28,6 @@ "babel-preset-minify": "^0.2.0", "chokidar": "^1.7.0", "chromedriver": "^2.32.3", - "less": "^2.7.2", - "nightwatch": "^0.9.16" + "less": "^3.0.4" } }