Skip to content
This repository was archived by the owner on Jun 2, 2023. It is now read-only.
Open
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension


Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
12 changes: 6 additions & 6 deletions node/hubController.js
Original file line number Diff line number Diff line change
Expand Up @@ -105,8 +105,8 @@ class HubController {
logger.verbose("refreshAuthToken()");
let opent2t = new OpenT2T(logger);

if (onboardingInfo) {
onboardingInfo.flights = this._getFlights(flightInfo);
if (existingAuthInfo) {
existingAuthInfo.flights = this._getFlights(flightInfo);
}

return this._getHubInfo(hubId, logger).then((hubInfo) => {
Expand All @@ -126,19 +126,19 @@ class HubController {
* Given a specific hub info, onboardingInfo, and existing authInfo blob,
* deauthorize the OAuthToken.
*/
deauthorizeToken(hubId, onboardingInfo, existingAuthInfo, logger, flightInfo){
deauthorizeToken(hubId, onboardingInfo, existingAuthInfo, logger, flightInfo) {
logger.verbose("deauthorizeToken()");

if (onboardingInfo) {
onboardingInfo.flights = this._getFlights(flightInfo);
if (existingAuthInfo) {
existingAuthInfo.flights = this._getFlights(flightInfo);
}

let opent2t = new OpenT2T(logger);
return this._getHubInfo(hubId, logger).then((hubInfo) => {

// create hub translator for given hubId
return this._createTranslator(opent2t, hubInfo.translator, existingAuthInfo).then((hubInstance) => {

// hub deauthorizeToken
return this._invokeMethod(opent2t, hubInstance, "", "deauthorizeToken", [onboardingInfo]);
});
Expand Down
2 changes: 1 addition & 1 deletion node/package.json
Original file line number Diff line number Diff line change
@@ -1,6 +1,6 @@
{
"name": "opent2t-cloud",
"version": "1.0.0",
"version": "1.0.1",
"description": "Helper classes and interface to manage opent2t cloud components. For now only the hubController management class",
"main": "hubController.js",
"files": [
Expand Down