diff --git a/utils/google-drive.js b/utils/google-drive.js index 884d4fe..3d87967 100644 --- a/utils/google-drive.js +++ b/utils/google-drive.js @@ -324,6 +324,15 @@ async function fetchFiles({folder, ...options}) { options, }) + // Fetching comments for each file + for (let file of documentsFiles) { + const comments = await drive.comments.list({ + fileId: file.id, + fields: 'comments' + }); + file.comments = comments.data.comments; + } + return documentsFiles }