fixed code copy