pachara-strike commented on code in PR #37280:
URL: https://github.com/apache/superset/pull/37280#discussion_r2716184806
##########
superset-embedded-sdk/src/index.ts:
##########
@@ -249,13 +249,14 @@ export async function embedDashboard({
ourPort.emit('guestToken', { guestToken });
log('sent guest token');
+ let refreshTokenTimerId: ReturnType<typeof setTimeout> | null = null;
async function refreshGuestToken() {
const newGuestToken = await fetchGuestToken();
ourPort.emit('guestToken', { guestToken: newGuestToken });
- setTimeout(refreshGuestToken, getGuestTokenRefreshTiming(newGuestToken));
+ refreshTokenTimerId = setTimeout(refreshGuestToken,
getGuestTokenRefreshTiming(newGuestToken));
}
Review Comment:
Fixed
--
This is an automated message from the Apache Git Service.
To respond to the message, please log on to GitHub and use the
URL above to go to the specific comment.
To unsubscribe, e-mail: [email protected]
For queries about this service, please contact Infrastructure at:
[email protected]
---------------------------------------------------------------------
To unsubscribe, e-mail: [email protected]
For additional commands, e-mail: [email protected]