fix case when object is empty