update credentials object after refresh

This commit is contained in:
Stephen Sawchuk
2015-03-25 16:11:20 -04:00
parent ec10a81513
commit c39f2a9dd3

View File

@@ -49,8 +49,8 @@ function callback(c, err, res) {
* @private
*/
UserRefreshClient.prototype.refreshToken_ = function(ignored_, opt_callback) {
UserRefreshClient.super_.prototype.refereshToken_.call(this._refreshToken,
opt_callback);
UserRefreshClient.super_.prototype.refreshToken_.call(
this, this._refreshToken, opt_callback);
};
/**
@@ -88,6 +88,7 @@ UserRefreshClient.prototype.fromJSON = function(json, opt_callback) {
that.clientId_ = json.client_id;
that.clientSecret_ = json.client_secret;
that._refreshToken = json.refresh_token;
that.credentials.refresh_token = json.refresh_token;
callback(opt_callback);
};