Skip to content

Commit fc1d79d

Browse files
committed
🔧Chore: remove ID_SIDEBAR as a valid response for draft container
the sidebar isn't being used as a container now, so this makes the code easier to understand
1 parent ab248fb commit fc1d79d

File tree

2 files changed

+2
-2
lines changed

2 files changed

+2
-2
lines changed

packages/web/src/common/utils/draft/draft.util.ts

Lines changed: 0 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -74,7 +74,5 @@ export const getDraftContainer = (category: Categories_Event) => {
7474
return getElemById(ID_GRID_EVENTS_ALLDAY);
7575
case Categories_Event.TIMED:
7676
return getElemById(ID_GRID_EVENTS_TIMED);
77-
default:
78-
return getElemById(ID_SIDEBAR);
7977
}
8078
};

packages/web/src/views/Calendar/components/Draft/Draft.tsx

Lines changed: 2 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -30,6 +30,8 @@ export const Draft: FC<Props> = ({ measurements, weekProps }) => {
3030
if (!category) return null;
3131

3232
const container = getDraftContainer(category);
33+
if (!container) return null;
34+
3335
const isGridDraft =
3436
category === Categories_Event.ALLDAY || category === Categories_Event.TIMED;
3537

0 commit comments

Comments
 (0)