Merged fix for rollup - 80% there