Workaround for arrays within grouped aggregations