Skip to content

There can be more than Notion and Miro. AFFiNE(pronounced [ə‘fain]) is a next-gen knowledge base that brings planning, sorting and creating all together. Privacy first, open-source, customizable and ready to use.

Remove double exclammation mark for function that already returns a boolean

Lynette Lopez68ab7d3968fc
diff --git a/libs/components/common/src/lib/text/EditableText.tsx b/libs/components/common/src/lib/text/EditableText.tsx
index 87c111544a..57509e9379 100644
--- a/libs/components/common/src/lib/text/EditableText.tsx
+++ b/libs/components/common/src/lib/text/EditableText.tsx
@@ -551,7 +551,7 @@ export const Text = forwardRef<ExtendedTextUtils, TextProps>((props, ref) => {
}
}
// markdown interception
- if (supportMarkdown && !!handleMarkdown(e)) {
+ if (supportMarkdown && handleMarkdown(e)) {
const start_selection = utils.current.getStartSelection();
utils.current.setSelection(start_selection);
e.preventDefault();