some small fixes for copy task with wrong directories