Skip to content

Commit

Permalink
merge: #2648
Browse files Browse the repository at this point in the history
2648: fix(auth-portal) fix bug during SSG in auth portal deployment notif r=theoephraim a=theoephraim

…ation

Co-authored-by: Theo Ephraim <[email protected]>
  • Loading branch information
si-bors-ng[bot] and Theo Ephraim authored Aug 18, 2023
2 parents 91b0c92 + 28aa203 commit ee13f13
Showing 1 changed file with 2 additions and 0 deletions.
2 changes: 2 additions & 0 deletions app/auth-portal/src/components/DeployNotification.vue
Original file line number Diff line number Diff line change
Expand Up @@ -51,6 +51,7 @@ function reloadBrowser() {
}
function getRunningHash() {
if (import.meta.env.SSR) return "";
// look for script tag of our main entrypoint that includes a hash
const scriptEls = document.querySelectorAll("script[src^='/assets/app-']");
for (const scriptEl of scriptEls) {
Expand All @@ -64,6 +65,7 @@ function stopInterval() {
if (window && intervalId) window.clearInterval(intervalId);
}
onMounted(() => {
if (import.meta.env.SSR) return;
// eslint-disable-next-line @typescript-eslint/no-floating-promises
check();
intervalId = window.setInterval(check, 2 * 60 * 1000);
Expand Down

0 comments on commit ee13f13

Please sign in to comment.