Skip to content

"rsync for cloud storage" - Google Drive, S3, Dropbox, Backblaze B2, One Drive, Swift, Hubic, Wasabi, Google Cloud Storage, Azure Blob, Azure Files, Yandex Files

protondrive: don't auth with an empty access token

Michał Dzienisiewicz4250dd98f39c
diff --git a/backend/protondrive/protondrive.go b/backend/protondrive/protondrive.go
index 192fe5374..415db44a8 100644
--- a/backend/protondrive/protondrive.go
+++ b/backend/protondrive/protondrive.go
@@ -285,6 +285,9 @@ func getConfigMap(m configmap.Mapper) (uid, accessToken, refreshToken, saltedKey
}
_saltedKeyPass = saltedKeyPass
+ // empty strings are considered "ok" by m.Get, which is not true business-wise
+ ok = accessToken != "" && uid != "" && refreshToken != "" && saltedKeyPass != ""
+
return
}