@bcc-code/vue-bcc-chat-ui 7.1.39 → 7.1.40

This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
@@ -4835,7 +4835,13 @@ function cc({ environment: e }) {
4835
4835
  return n();
4836
4836
  }
4837
4837
  async function ft() {
4838
- let e = await H.getLoggedInUser();
4838
+ let e = await H.getLoggedinUser();
4839
+ if (!e) try {
4840
+ e = await H.getLoggedInUser();
4841
+ } catch (e) {
4842
+ if (e && typeof e == "object" && "code" in e && e.code === "USER_NOT_LOGED_IN") return;
4843
+ console.error("Error fetching logged in user:", e);
4844
+ }
4839
4845
  _.value = e ? hc(e) : null, h.value = !!e;
4840
4846
  }
4841
4847
  function pt() {
@@ -9819,7 +9825,13 @@ var uf = { class: "w-full" }, df = {
9819
9825
  () => f.client ? f.client.loggedIn.value : gu.loggedIn.value,
9820
9826
  () => T.value?.conversations.value.length ?? 0
9821
9827
  ], async ([e, t, n]) => {
9822
- !D.value || !e || !t || !n || !T.value || await ae();
9828
+ console.log("Watcher triggered for conversation loading.", {
9829
+ chatUid: e,
9830
+ initialized: t,
9831
+ loggedIn: n,
9832
+ activeClientConversations: T.value?.conversations.value.length ?? 0,
9833
+ client: f.client
9834
+ }), !(!D.value || !e || !t || !n || !T.value) && await ae();
9823
9835
  }, { immediate: !0 }), F([
9824
9836
  () => P.messages.value.length,
9825
9837
  () => P.threadMessages.value.length,