Explorar el Código

fix: don't run <rtc-get-users-info when starting rtc

Tienson Qin hace 1 mes
padre
commit
5cf7fed1e0

+ 2 - 2
src/main/frontend/components/page.cljs

@@ -182,8 +182,8 @@
           quick-add-page-id (:db/id (db-db/get-built-in-page (db/get-db) common-config/quick-add-page-name))
           children (cond
                      (and (= id quick-add-page-id)
-                          (> (count (get @(:rtc/users-info @state/state) (state/get-current-repo))) 1)
-                          (user-handler/user-uuid)) ; other collaborator
+                          (user-handler/user-uuid)
+                          (ldb/get-graph-rtc-uuid (db/get-db)))
                      (let [user-id (uuid (user-handler/user-uuid))
                            user-db-id (:db/id (db/entity [:block/uuid user-id]))]
                        (if user-db-id

+ 0 - 1
src/main/frontend/handler/db_based/rtc.cljs

@@ -110,7 +110,6 @@
      (js/Promise. user-handler/task--ensure-id&access-token)
      (p/let [start-ex (state/<invoke-db-worker :thread-api/rtc-start stop-before-start?)
              ex-data* (:ex-data start-ex)
-             _ (<rtc-get-users-info)
              _ (case (:type ex-data*)
                  (:rtc.exception/not-rtc-graph
                   :rtc.exception/not-found-db-conn)