change attributes logic