diff --git a/lib/src/Components/Input/RichTextEditor.tsx b/lib/src/Components/Input/RichTextEditor.tsx index f504e0ad..01045291 100644 --- a/lib/src/Components/Input/RichTextEditor.tsx +++ b/lib/src/Components/Input/RichTextEditor.tsx @@ -44,7 +44,7 @@ export function RichTextEditor({ const regex = /!\[.*?\]\(.*?\)/g newValue = newValue.replace(regex, (match: string) => match + '\n\n') - if (updateFormValue && newValue) { + if (updateFormValue) { updateFormValue(newValue) } } diff --git a/lib/src/Components/Profile/itemFunctions.ts b/lib/src/Components/Profile/itemFunctions.ts index b26c7142..46ae25ce 100644 --- a/lib/src/Components/Profile/itemFunctions.ts +++ b/lib/src/Components/Profile/itemFunctions.ts @@ -273,7 +273,7 @@ export const onUpdateItem = async ( setLoading(true) state.text - .toLocaleLowerCase() + ?.toLocaleLowerCase() .match(hashTagRegex) ?.map((tag) => { if (!tags.find((t) => t.name.toLocaleLowerCase() === tag.slice(1).toLocaleLowerCase())) {