Fixed some little bug on Upload class when copying to an existing file