improve callback method and fix callback call on FTP upload