File tree Expand file tree Collapse file tree 1 file changed +4
-3
lines changed
Expand file tree Collapse file tree 1 file changed +4
-3
lines changed Original file line number Diff line number Diff line change 1515PYDRIVE_CREDENTIALS = 'PYDRIVE_CREDENTIALS'
1616
1717LOGGER = logging .getLogger (__name__ )
18+ GDRIVE_LINK = 'gdrive://'
1819
1920
2021def is_drive_path (path ):
2122 """Tell if the drive is a Google Drive path or not."""
22- return path .startswith ('gdrive://' )
23+ return path .startswith (GDRIVE_LINK )
2324
2425
2526def split_drive_path (path ):
@@ -137,8 +138,8 @@ def get_or_create_gdrive_folder(parent_folder: str, folder_name: str) -> str:
137138 drive = _get_drive_client ()
138139
139140 # Check if folder already exists
140- if parent_folder .startswith ('gdrive://' ):
141- parent_folder = parent_folder .replace ('gdrive://' , '' )
141+ if parent_folder .startswith (GDRIVE_LINK ):
142+ parent_folder = parent_folder .replace (GDRIVE_LINK , '' )
142143
143144 query = {
144145 'q' : f"title = '{ folder_name } ' and mimeType = 'application/vnd.google-apps.folder' "
You can’t perform that action at this time.
0 commit comments