added checks in hobj.py