commit | c8e992af94b2ea9b4b58e82d044a6aba28f008a6 | [log] [tgz] |
---|---|---|
author | Chris Poucet <poucet@google.com> | Mon Oct 24 13:52:34 2022 +0200 |
committer | Chris Poucet <christophe.poucet@gmail.com> | Mon Oct 24 23:31:39 2022 +0200 |
tree | 377f3eac9bf0f6a1aa55b0f80a46b2432fa67efe | |
parent | bb0cf83a6745dd63286dc0e0ba5b993b30e5b84e [diff] [blame] |
Make sure that gr-router#finalize is safe to be called more than once. This is necessary as GrRouter is registered under two different tokens. Release-Notes: skip Change-Id: Iaa3a0b7e81c97abdc33fd373540771511bb3d97b
diff --git a/polygerrit-ui/app/elements/core/gr-router/gr-router.ts b/polygerrit-ui/app/elements/core/gr-router/gr-router.ts index 2bda156..b90ef91 100644 --- a/polygerrit-ui/app/elements/core/gr-router/gr-router.ts +++ b/polygerrit-ui/app/elements/core/gr-router/gr-router.ts
@@ -343,6 +343,7 @@ for (const subscription of this.subscriptions) { subscription.unsubscribe(); } + this.subscriptions = []; } start() {