add refreshToken

This commit is contained in:
AJ ONeal 2017-01-19 01:23:08 +00:00
parent 30d62f94e0
commit 4c5d57fd8c
1 changed files with 14 additions and 0 deletions

View File

@ -194,6 +194,20 @@
}); });
}; };
oauth3.refreshToken = function (providerUri, opts) {
return oauth3.discover(providerUri, opts).then(function (directive) {
var prequest = core.refreshToken(directive, opts);
console.log('[DEBUG] [core] refreshToken URL', prequest);
return oauth3.request({
url: prequest.url
, method: prequest.method
, data: prequest.data
});
});
};
oauth3.frameRequest = function (url, state, opts) { oauth3.frameRequest = function (url, state, opts) {
var promise; var promise;