gsuite-drive-manager
Advanced tools
Comparing version 0.0.7 to 0.0.8
18
index.js
@@ -165,2 +165,19 @@ /*global require, console, Promise*/ | ||
function hasParent(file, parentId, allFiles, rootFolderId) { | ||
if (file.parents === undefined) { | ||
return false; | ||
} | ||
if (file.parents.indexOf(parentId) !== -1) { | ||
return true; | ||
} | ||
return file.parents.some(function (parent) { | ||
if (parent === rootFolderId) { | ||
return false; | ||
} | ||
return hasParent(allFiles[parent], parentId, allFiles, rootFolderId); | ||
}); | ||
} | ||
function download(specs) { | ||
@@ -694,2 +711,3 @@ | ||
deleteParents: deleteParents, | ||
hasParent: hasParent, | ||
deletePermission: deletePermission, | ||
@@ -696,0 +714,0 @@ deleteFile: deleteFile, |
{ | ||
"name": "gsuite-drive-manager", | ||
"version": "0.0.7", | ||
"version": "0.0.8", | ||
"description": "A wrapper for the G suite drive SDK", | ||
"main": "index.js", | ||
"dependencies": { | ||
"google-auth-library": "^0.12.0", | ||
"googleapis": "^23.0.0", | ||
@@ -9,0 +8,0 @@ "retry": "^0.10.1" |
26639
2
634
- Removedgoogle-auth-library@^0.12.0