drive: set the IncludeCorpusRemovals flag so changes returns deletes

Without this flag changes does not include files which were hard
deleted.

Fixes #3020
This commit is contained in:
Nick Craig-Wood 2019-03-05 14:37:46 +00:00
parent 1692c6bd0a
commit ec40ffbdc1
1 changed files with 1 additions and 1 deletions

View File

@ -2203,7 +2203,7 @@ func (f *Fs) changeNotifyRunner(notifyFunc func(string, fs.EntryType), startPage
var changeList *drive.ChangeList
err = f.pacer.Call(func() (bool, error) {
changesCall := f.svc.Changes.List(pageToken).
changesCall := f.svc.Changes.List(pageToken).IncludeCorpusRemovals(true).
Fields("nextPageToken,newStartPageToken,changes(fileId,file(name,parents,mimeType))")
if f.opt.ListChunk > 0 {
changesCall.PageSize(f.opt.ListChunk)