From 3cd0c54438d632c1862bb75701ecfcff4b6b0734 Mon Sep 17 00:00:00 2001 From: Suraj Shetty Date: Tue, 21 Aug 2018 16:29:06 +0530 Subject: [PATCH] Fix pyhton 3 compatibility --- erpnext/hub_node/api.py | 3 ++- 1 file changed, 2 insertions(+), 1 deletion(-) diff --git a/erpnext/hub_node/api.py b/erpnext/hub_node/api.py index 6e11a86b864..85693c72af5 100644 --- a/erpnext/hub_node/api.py +++ b/erpnext/hub_node/api.py @@ -3,12 +3,13 @@ import frappe, requests, json from frappe.utils import now from frappe.frappeclient import FrappeClient from frappe.desk.form.load import get_attachments +from six import string_types @frappe.whitelist() def call_hub_method(method, params=None): connection = get_hub_connection() - if type(params) == unicode: + if isinstance(params, string_types): params = json.loads(params) params.update({