lib/rest-ftp-daemon/remote/ftp.rb in rest-ftp-daemon-1.0.4 vs lib/rest-ftp-daemon/remote/ftp.rb in rest-ftp-daemon-1.0.5

- old
+ new

@@ -32,21 +32,21 @@ @ftp.connect @target.host, @target.port @ftp.login @target.user, @target.password end def size_if_exists target - size = @ftp.size target.filepath + size = @ftp.size target.path_fs log_debug "size_if_exists [#{target.name}]" rescue Net::FTPPermError return false else return size end def remove! target - @ftp.delete target.filepath + @ftp.delete target.path_fs rescue Net::FTPPermError log_debug "remove! [#{target.name}] not found" else log_debug "remove! [#{target.name}] removed" end @@ -101,15 +101,15 @@ if use_temp_name dest.generate_temp_name! end # Move to the directory - log_debug "upload chdir [#{dest.filedir}]" - @ftp.chdir dest.filedir + log_debug "upload chdir [#{dest.dir_fs}]" + @ftp.chdir dest.dir_fs # Do the transfer - log_debug "upload putbinaryfile [#{source.filepath}] [#{dest.name}]" - @ftp.putbinaryfile source.filepath, dest.name, JOB_FTP_CHUNKMB do |data| + log_debug "upload putbinaryfile [#{source.path_fs}] [#{dest.name}]" + @ftp.putbinaryfile source.path_fs, dest.name, JOB_FTP_CHUNKMB do |data| # Update job status after this block transfer yield data.bytesize, dest.name end # Move the file back to its original name \ No newline at end of file