Correct bug in copying parameters