bug fix during copy