refactor: parse native JSON request args in accounts/doctype/account/chart_of_accounts/chart_of_accounts.py

Use frappe.parse_json instead of json.loads so the whitelisted endpoints
accept native JSON types (list/dict/bool) in addition to JSON strings.
This commit is contained in:
Mihir Kandoi
2026-06-24 20:37:30 +05:30
parent 9b0e1b61f2
commit a869b748f1

View File

@@ -137,7 +137,7 @@ def get_charts_for_country(country: str, with_standard: bool = False):
def _get_chart_name(content):
if content:
content = json.loads(content)
content = frappe.parse_json(content)
if (
content and content.get("disabled", "No") == "No"
) or frappe.local.flags.allow_unverified_charts: