gdriveTools: Handle unhandled exception in clone method
Signed-off-by: lzzy12 <jhashivam2020@gmail.com>
This commit is contained in:
parent
b84d4aca2c
commit
47dd3c2b6f
|
|
@ -246,7 +246,14 @@ class GoogleDriveHelper:
|
|||
|
||||
def clone(self, link):
|
||||
self.transferred_size = 0
|
||||
file_id = self.getIdFromUrl(link)
|
||||
try:
|
||||
file_id = self.getIdFromUrl(link)
|
||||
except KeyError:
|
||||
msg = "Google drive ID could not be found in the provided link"
|
||||
return msg
|
||||
except IndexError:
|
||||
msg = "Google drive ID could not be found in the provided link"
|
||||
return msg
|
||||
msg = ""
|
||||
LOGGER.info(f"File ID: {file_id}")
|
||||
try:
|
||||
|
|
|
|||
Loading…
Reference in New Issue