fix: take country from doctype at signup

This commit is contained in:
Jannat Patel
2022-04-14 09:03:18 +05:30
parent ab7ebedcd5
commit ef43d6905f

View File

@@ -249,7 +249,7 @@ def get_country_code():
try:
data = res.json()
if data.get("status") != "fail":
return data.get("country")
return frappe.db.get_value("Country", {"code": data.get("countryCode")}, "name")
except Exception:
pass
return