"rsync for cloud storage" - Google Drive, S3, Dropbox, Backblaze B2, One Drive, Swift, Hubic, Wasabi, Google Cloud Storage, Azure Blob, Azure Files, Yandex Files
Go azure-blobazure-blob-storageazure-filesbackblaze-b2cloud-storagedropboxencryptionftpfuse-filesystemgogolanggoogle-cloud-storagegoogle-driveonedriveopenstack-swiftrclones3sftpsyncwebdav
sftp: fix detection of file vs directory
Nick Craig-Wood84b12574de05
diff --git a/sftp/sftp.go b/sftp/sftp.goindex 6a08b2a1d..cefee2550 100644--- a/sftp/sftp.go+++ b/sftp/sftp.go@@ -151,7 +151,7 @@ func NewFs(name, root string) (fs.Fs, error) {}_, err := f.NewObject(remote)if err != nil {- if err == fs.ErrorObjectNotFound {+ if err == fs.ErrorObjectNotFound || errors.Cause(err) == fs.ErrorNotAFile {// File doesn't exist so return old ff.root = rootreturn f, nil