mirror of
https://github.com/janeczku/calibre-web
synced 2025-01-13 02:40:29 +00:00
Bugfix finding settings.yaml and dgrive_credentials file
This commit is contained in:
parent
7d3fadb685
commit
9ca454730c
@ -74,9 +74,9 @@ migrate()
|
|||||||
def getDrive(drive=None, gauth=None):
|
def getDrive(drive=None, gauth=None):
|
||||||
if not drive:
|
if not drive:
|
||||||
if not gauth:
|
if not gauth:
|
||||||
gauth = GoogleAuth(settings_file='settings.yaml')
|
gauth = GoogleAuth(settings_file=os.path.join(config.get_main_dir,'settings.yaml'))
|
||||||
# Try to load saved client credentials
|
# Try to load saved client credentials
|
||||||
gauth.LoadCredentialsFile("gdrive_credentials")
|
gauth.LoadCredentialsFile(os.path.join(config.get_main_dir,'gdrive_credentials'))
|
||||||
if gauth.access_token_expired:
|
if gauth.access_token_expired:
|
||||||
# Refresh them if expired
|
# Refresh them if expired
|
||||||
try:
|
try:
|
||||||
|
Loading…
Reference in New Issue
Block a user