Fix bug where loading credentials from ENV doesn't set the credentials in the UserRefreshCredentials

This commit is contained in:
David Wilkie committed 2015-06-26 14:31:09 +07:00
1 parent dc12124faf
commit 15fbf92199
2 files changed
+6 -3

No files matched your search

+3 -3
View File
@@ -67,9 +67,9 @@ module Google
json_key_io, scope = options.values_at(:json_key_io, :scope)
user_creds = self.class.read_json_key(json_key_io) if json_key_io
user_creds ||= {
client_id: ENV[CredentialsLoader::CLIENT_ID_VAR],
client_secret: ENV[CredentialsLoader::CLIENT_SECRET_VAR],
refresh_token: ENV[CredentialsLoader::REFRESH_TOKEN_VAR]
'client_id' => ENV[CredentialsLoader::CLIENT_ID_VAR],
'client_secret' => ENV[CredentialsLoader::CLIENT_SECRET_VAR],
'refresh_token' => ENV[CredentialsLoader::REFRESH_TOKEN_VAR]
}
super(token_credential_uri: TOKEN_CRED_URI,