Fixed bug in utils.py and json_obj_template