Minor fix for copy local and MaterializedIndex