[refactor] used each for object properties iteration