diff --git a/apps/client/src/widgets/dialogs/add_link.spec.tsx b/apps/client/src/widgets/dialogs/add_link.spec.tsx index 7525712185..95765a0d62 100644 --- a/apps/client/src/widgets/dialogs/add_link.spec.tsx +++ b/apps/client/src/widgets/dialogs/add_link.spec.tsx @@ -46,7 +46,7 @@ vi.mock("../../services/note_autocomplete", () => ({ })); vi.mock("../react/react_utils", () => ({ - refToJQuerySelector: (ref: { current: HTMLInputElement | null }) => $(ref.current) + refToJQuerySelector: (ref: { current: HTMLInputElement | null }) => ref.current ? $(ref.current) : $() })); vi.mock("../react/hooks", () => ({