changed forEach to for in constructor and concat