Skip to content

Open-Source API Development Ecosystem • https://hoppscotch.io • Offline, On-Prem & Cloud • Web, Desktop & CLI • Open-Source Alternative to Postman, Insomnia

fix(common): prevent exception with `ShortcodeListAdapter` initialization (#3917)

James Georgee53382666a83
diff --git a/packages/hoppscotch-common/src/components/share/index.vue b/packages/hoppscotch-common/src/components/share/index.vue
index 164318473..3a635f517 100644
--- a/packages/hoppscotch-common/src/components/share/index.vue
+++ b/packages/hoppscotch-common/src/components/share/index.vue
@@ -273,6 +273,10 @@ const loading = computed(
)
onLoggedIn(() => {
+ if (adapter.isInitialized()) {
+ return
+ }
+
try {
// wait for a bit to let the auth token to be set
// because in some race conditions, the token is not set this fixes that