Commit 5b6f29c7 authored by Rob Carleski's avatar Rob Carleski 🇮🇸
Browse files

Fix parent folders in reports

parent 86e7734a
...@@ -91,7 +91,6 @@ class Sifter: ...@@ -91,7 +91,6 @@ class Sifter:
for child in children: for child in children:
if not hasattr(self, 'ignore_owner'): if not hasattr(self, 'ignore_owner'):
if self.account != child['owners.0.emailAddress']: if self.account != child['owners.0.emailAddress']:
print(child['owners.0.emailAddress'])
continue continue
data = { data = {
...@@ -102,14 +101,15 @@ class Sifter: ...@@ -102,14 +101,15 @@ class Sifter:
'parent': '\\'.join(self.parent) 'parent': '\\'.join(self.parent)
} }
self.parent.append(child['title'])
if in_private or child['title'].lower() in self.omit_folders: if in_private or child['title'].lower() in self.omit_folders:
self.private_files[child['id']] = data self.private_files[child['id']] = data
if 'folder' in child['mimeType']: if 'folder' in child['mimeType']:
self.parent.append(child['title'])
self.sift(child['id'], in_private=True) self.sift(child['id'], in_private=True)
else: else:
self.transfer_files[child['id']] = data self.transfer_files[child['id']] = data
if 'folder' in child['mimeType']: if 'folder' in child['mimeType']:
self.parent.append(child['title'])
self.sift(child['id'], in_private=False) self.sift(child['id'], in_private=False)
self.parent.pop() self.parent.pop()
......
Supports Markdown
0% or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment