From 5531c3c33c6dd8ab7d9ee1c8cc1c91c02f8afb0d Mon Sep 17 00:00:00 2001 From: sua yoo Date: Sun, 5 Dec 2021 16:52:58 -0800 Subject: [PATCH] hotfix: fix auth persist Switch lifecycle event to update --- frontend/src/utils/auth.ts | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/frontend/src/utils/auth.ts b/frontend/src/utils/auth.ts index 3174131b..008f7b15 100644 --- a/frontend/src/utils/auth.ts +++ b/frontend/src/utils/auth.ts @@ -24,9 +24,9 @@ export function needLogin( }; } - connectedCallback() { + update(changedProperties: Map) { if (this.authState) { - super.connectedCallback(); + super.update(changedProperties); } else { this.dispatchEvent(new CustomEvent("need-login")); }