From 22d90df8643049d29c5640f01b631b8c51b1efd6 Mon Sep 17 00:00:00 2001 From: Faris Ansari Date: Fri, 1 Jun 2018 12:03:24 +0530 Subject: [PATCH 1/3] NPM Audit fix (#5645) - remove unused nightwatch - update less to 3.0.4 --- package.json | 3 +-- 1 file changed, 1 insertion(+), 2 deletions(-) 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" } } From ad64ef5c4ed42bae6c1b8472f86ddd35e0768d8d Mon Sep 17 00:00:00 2001 From: Faris Ansari Date: Tue, 5 Jun 2018 14:44:49 +0530 Subject: [PATCH 2/3] [fix] Incorrect email account as sender (#5657) If there are multiple Email Accounts with the same append_to, then the first one is fetched which is incorrect if there is an Email Account for the current user. Now it is first filtered by email_id, if not found falls back to old behaviour. --- frappe/email/smtp.py | 18 +++++++++++++++++- 1 file changed, 17 insertions(+), 1 deletion(-) 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 From 8d0b33c5ca10efa4a20bc5a6067f356b2c4c0f43 Mon Sep 17 00:00:00 2001 From: Saurabh Date: Tue, 5 Jun 2018 15:42:57 +0600 Subject: [PATCH 3/3] bumped to version 10.1.36 --- frappe/__init__.py | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) 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()