Skip to content

Commit

Permalink
Fix Bug 54825 - Client.Clouds.‘Uncaught (in promise) undefined’
Browse files Browse the repository at this point in the history
  • Loading branch information
AlexeySafronov committed Feb 15, 2022
1 parent a67773b commit 5e12bf5
Show file tree
Hide file tree
Showing 2 changed files with 10 additions and 5 deletions.
5 changes: 3 additions & 2 deletions packages/asc-web-common/store/SettingsStore.js
Original file line number Diff line number Diff line change
Expand Up @@ -251,8 +251,9 @@ class SettingsStore {
clearInterval(interval);
reject();
}
} catch {
return;
} catch (e) {
clearInterval(interval);
reject(e);
}
}, 500);
});
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -109,12 +109,16 @@ const ThirdPartyDialog = (props) => {
"Authorization",
"height=600, width=1020"
);
openConnectWindow(item.title, authModal).then((modal) =>
getOAuthToken(modal).then((token) => {
openConnectWindow(item.title, authModal)
.then(getOAuthToken)
.then((token) => {
authModal.close();
showOAuthModal(token, item);
})
);
.catch((e) => {
if (!e) return;
console.error(e);
});
} else {
item.title = connectedCloudsTitleTranslation(item.title, t);
setConnectItem(item);
Expand Down

0 comments on commit 5e12bf5

Please sign in to comment.