From f85e3209b3b474b8b00dbb080b832c4de46d013b Mon Sep 17 00:00:00 2001 From: Nick Craig-Wood Date: Sun, 31 Oct 2021 16:13:39 +0000 Subject: [PATCH] premiumizeme: fix directory listing after API changes The API doesn't seem to accept a value of "0" any more for the root directory ID, giving the error "Could not decode folder id". However omitting it seems to work fine. --- backend/premiumizeme/premiumizeme.go | 4 +++- 1 file changed, 3 insertions(+), 1 deletion(-) diff --git a/backend/premiumizeme/premiumizeme.go b/backend/premiumizeme/premiumizeme.go index de71cf06f..a608acf60 100644 --- a/backend/premiumizeme/premiumizeme.go +++ b/backend/premiumizeme/premiumizeme.go @@ -401,7 +401,9 @@ func (f *Fs) listAll(ctx context.Context, dirID string, directoriesOnly bool, fi Path: "/folder/list", Parameters: f.baseParams(), } - opts.Parameters.Set("id", dirID) + if dirID != rootID { + opts.Parameters.Set("id", dirID) + } opts.Parameters.Set("includebreadcrumbs", "false") var result api.FolderListResponse