Skip to content

Commit 54303d6

Browse files
authored
Merge pull request #1578 from session-foundation/fix-password-crash
fix: crash on password window
2 parents 0dcb507 + c057f26 commit 54303d6

File tree

1 file changed

+1
-1
lines changed

1 file changed

+1
-1
lines changed

ts/state/selectors/modal.ts

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -117,7 +117,7 @@ export function useConversationSettingsModalIsStandalone() {
117117
}
118118

119119
export function useModalStack() {
120-
return useSelector((state: StateType) => state.modals.modalStack);
120+
return useSelector((state: StateType) => state.modals?.modalStack ?? []); // that [] is needed for the password window
121121
}
122122

123123
export function useIsTopModal(modalId: ModalId) {

0 commit comments

Comments
 (0)