fixed aggregate repository bug