From ec4b3d913e27537f9ad39bfcd2785729f5bc8432 Mon Sep 17 00:00:00 2001 From: Seunghyun oh Date: Fri, 16 Sep 2022 04:58:07 +0900 Subject: [PATCH] fix: remove no longer used code related to collab room loading (#5699) Co-authored-by: dwelle --- src/excalidraw-app/app_constants.ts | 1 - src/excalidraw-app/collab/Collab.tsx | 13 ------------- 2 files changed, 14 deletions(-) diff --git a/src/excalidraw-app/app_constants.ts b/src/excalidraw-app/app_constants.ts index cbead768..e56f7b24 100644 --- a/src/excalidraw-app/app_constants.ts +++ b/src/excalidraw-app/app_constants.ts @@ -33,7 +33,6 @@ export const STORAGE_KEYS = { LOCAL_STORAGE_ELEMENTS: "excalidraw", LOCAL_STORAGE_APP_STATE: "excalidraw-state", LOCAL_STORAGE_COLLAB: "excalidraw-collab", - LOCAL_STORAGE_KEY_COLLAB_FORCE_FLAG: "collabLinkForceLoadFlag", LOCAL_STORAGE_LIBRARY: "excalidraw-library", VERSION_DATA_STATE: "version-dataState", VERSION_FILES: "version-files", diff --git a/src/excalidraw-app/collab/Collab.tsx b/src/excalidraw-app/collab/Collab.tsx index 7112671c..363de949 100644 --- a/src/excalidraw-app/collab/Collab.tsx +++ b/src/excalidraw-app/collab/Collab.tsx @@ -25,7 +25,6 @@ import { INITIAL_SCENE_UPDATE_TIMEOUT, LOAD_IMAGES_TIMEOUT, WS_SCENE_EVENT_TYPES, - STORAGE_KEYS, SYNC_FULL_SCENE_INTERVAL_MS, } from "../app_constants"; import { @@ -225,18 +224,6 @@ class Collab extends PureComponent { preventUnload(event); } - - if (this.isCollaborating || this.portal.roomId) { - try { - localStorage?.setItem( - STORAGE_KEYS.LOCAL_STORAGE_KEY_COLLAB_FORCE_FLAG, - JSON.stringify({ - timestamp: Date.now(), - room: this.portal.roomId, - }), - ); - } catch {} - } }); saveCollabRoomToFirebase = async (