From a20800ee2b9c2472acbb1584db95aa58769dcbba Mon Sep 17 00:00:00 2001 From: gavin Date: Thu, 19 May 2022 17:45:22 +0530 Subject: [PATCH] fix: mport module from line N shadowed by loop variable Flake8 F402 reported by sider --- frappe/database/query.py | 6 +++--- 1 file changed, 3 insertions(+), 3 deletions(-) diff --git a/frappe/database/query.py b/frappe/database/query.py index 6297e297a4..70127dd9d9 100644 --- a/frappe/database/query.py +++ b/frappe/database/query.py @@ -181,11 +181,11 @@ class Query: warn("'filters_config' hook is not completely implemented yet in frappe.db.query engine") - for operator, function in additional_filters_config.items(): + for _operator, function in additional_filters_config.items(): if callable(function): - all_operators.update({operator.casefold(): function}) + all_operators.update({_operator.casefold(): function}) elif isinstance(function, dict): - all_operators[operator.casefold()] = frappe.get_attr(function.get("get_field"))()["operator"] + all_operators[_operator.casefold()] = frappe.get_attr(function.get("get_field"))()["operator"] return all_operators