googleDrive removed, use isdigit() on object directly

This commit is contained in:
Rob Weber 2019-09-30 14:36:54 -05:00
parent c50c5245fc
commit 048d016e0e

View File

@ -88,7 +88,7 @@ class XbmcBackup:
file_ext = aFile.split('.')[-1] file_ext = aFile.split('.')[-1]
folderName = aFile.split('.')[0] folderName = aFile.split('.')[0]
if(file_ext == 'zip' and len(folderName) == 12 and str.isdigit(folderName)): if(file_ext == 'zip' and len(folderName) == 12 and folderName.isdigit()):
#format the name according to regional settings #format the name according to regional settings
folderName = self._dateFormat(folderName) folderName = self._dateFormat(folderName)
@ -496,7 +496,7 @@ class XbmcBackup:
result = None result = None
#copy the file and open it #copy the file and open it
if(isinstance(self.remote_vfs,DropboxFileSystem) or isinstance(self.remote_vfs,GoogleDriveFilesystem)): if(isinstance(self.remote_vfs,DropboxFileSystem)):
self.remote_vfs.get_file(path + "xbmcbackup.val", xbmc.translatePath(utils.data_dir() + "xbmcbackup_restore.val")) self.remote_vfs.get_file(path + "xbmcbackup.val", xbmc.translatePath(utils.data_dir() + "xbmcbackup_restore.val"))
else: else:
self.xbmc_vfs.put(path + "xbmcbackup.val",xbmc.translatePath(utils.data_dir() + "xbmcbackup_restore.val")) self.xbmc_vfs.put(path + "xbmcbackup.val",xbmc.translatePath(utils.data_dir() + "xbmcbackup_restore.val"))