🐛 fix(gmail): fix token persistence path
- Use the persist_path from the config instead of a hardcoded path to ensure tokens are persisted to the correct location
This commit is contained in:
committed by
Jeremiah Russell
parent
368e78b1cc
commit
73e9eed539
@@ -72,13 +72,14 @@ impl GmailClient {
|
||||
.build();
|
||||
|
||||
let client = Client::builder(executor.clone()).build(connector.clone());
|
||||
log::trace!("file to persist tokens to `{}`", config.persist_path());
|
||||
|
||||
let auth = InstalledFlowAuthenticator::with_client(
|
||||
config.secret().clone(),
|
||||
InstalledFlowReturnMethod::HTTPRedirect,
|
||||
Client::builder(executor).build(connector),
|
||||
)
|
||||
.persist_tokens_to_disk(format!("{}/gmail1", config.config_root()))
|
||||
.persist_tokens_to_disk(config.persist_path())
|
||||
.build()
|
||||
.await
|
||||
.unwrap();
|
||||
|
||||
Reference in New Issue
Block a user