Skip to content

Commit

Permalink
- Add support for Google Team Drives
Browse files Browse the repository at this point in the history
  • Loading branch information
KoalaBear84 committed Nov 23, 2020
1 parent e00d869 commit 5d17e22
Showing 1 changed file with 2 additions and 0 deletions.
2 changes: 2 additions & 0 deletions OpenDirectoryDownloader.GoogleDrive/GoogleDriveIndexer.cs
Original file line number Diff line number Diff line change
Expand Up @@ -85,6 +85,8 @@ public static async Task<WebDirectory> IndexAsync(WebDirectory webDirectory)
listRequest.Q = $"'{folderId}' in parents";
listRequest.PageToken = nextPageToken;
listRequest.Fields = "nextPageToken, files(id, name, mimeType, size)";
listRequest.IncludeItemsFromAllDrives = true;
listRequest.SupportsAllDrives = true;
Google.Apis.Drive.v3.Data.FileList fileList = await listRequest.ExecuteAsync();

foreach (Google.Apis.Drive.v3.Data.File file in fileList.Files.OrderByDescending(f => f.MimeType == FolderMimeType).ThenBy(f => f.Name))
Expand Down

0 comments on commit 5d17e22

Please sign in to comment.