Skip to content

Commit bf40257

Browse files
refactor: coerce to boolean.
1 parent 9be9c66 commit bf40257

1 file changed

Lines changed: 3 additions & 1 deletion

File tree

  • src/modules/workspace/workspaces-drawer

src/modules/workspace/workspaces-drawer/drawer.js

Lines changed: 3 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -153,7 +153,9 @@ export const createWorkspacesDrawer = ({
153153
typeof getActiveWorkspaceId === 'function' ? toSafeText(getActiveWorkspaceId()) : ''
154154
const hasSelection = normalizedSelectedId.length > 0
155155
const isSelectedWorkspaceActive =
156-
hasSelection && activeWorkspaceId && normalizedSelectedId === activeWorkspaceId
156+
hasSelection &&
157+
Boolean(activeWorkspaceId) &&
158+
normalizedSelectedId === activeWorkspaceId
157159
const canCreateWorkspace = typeof onCreateWorkspace === 'function'
158160
const canInitializeWorkspace = typeof onInitializeWorkspace === 'function'
159161
const hasStoredWorkspaces =

0 commit comments

Comments
 (0)