putio: use lib/encoder
And in the process - fix a bug with + and & in file name - fix NewObject returning directories as files
This commit is contained in:
@@ -238,6 +238,16 @@ const Pcloud = encoder.MultiEncoder(
|
||||
encoder.EncodeBackSlash |
|
||||
encoder.EncodeInvalidUtf8)
|
||||
|
||||
// Putio is the encoding used by the putio backend
|
||||
//
|
||||
// Note that \ is renamed to -
|
||||
//
|
||||
// Encode invalid UTF-8 bytes as json doesn't handle them properly.
|
||||
const Putio = encoder.MultiEncoder(
|
||||
uint(Display) |
|
||||
encoder.EncodeBackSlash |
|
||||
encoder.EncodeInvalidUtf8)
|
||||
|
||||
// Fichier is the encoding used by the fichier backend
|
||||
//
|
||||
// Characters that need escaping
|
||||
|
||||
@@ -29,8 +29,11 @@ const (
|
||||
OneDrive = Base
|
||||
OpenDrive = Base
|
||||
Pcloud = Base
|
||||
PremiumizeMe = Base
|
||||
Putio = Base
|
||||
QingStor = Base
|
||||
S3 = Base
|
||||
Sharefile = Base
|
||||
Swift = Base
|
||||
)
|
||||
|
||||
|
||||
Reference in New Issue
Block a user