fix NameError: restore company variable in create_default_salary_components

Co-Authored-By: Claude Sonnet 4.6 <noreply@anthropic.com>
This commit is contained in:
Ali 2026-03-26 16:41:41 +04:00
parent 6b3324704c
commit ea5847b353
1 changed files with 2 additions and 0 deletions

View File

@ -27,6 +27,8 @@ def create_default_salary_components(args):
if not os.path.exists(SALARY_COMPONENTS_JSON):
return
company = args.get("company_name") or frappe.db.get_single_value("Global Defaults", "default_company")
with open(SALARY_COMPONENTS_JSON, encoding="utf-8") as f:
components = json.load(f)