mirror of
https://github.com/versia-pub/server.git
synced 2025-12-06 16:38:19 +01:00
Don't replace text mentions twice
This commit is contained in:
parent
fde0ff509e
commit
742913a911
|
|
@ -299,17 +299,14 @@ export const createNewStatus = async (
|
|||
.map((line) => `<p>${line}</p>`)
|
||||
.join("\n");
|
||||
|
||||
htmlContent = linkifyHtml(
|
||||
await replaceTextMentions(htmlContent, mentions ?? []),
|
||||
{
|
||||
defaultProtocol: "https",
|
||||
validate: {
|
||||
email: () => false,
|
||||
},
|
||||
target: "_blank",
|
||||
rel: "nofollow noopener noreferrer",
|
||||
htmlContent = linkifyHtml(htmlContent, {
|
||||
defaultProtocol: "https",
|
||||
validate: {
|
||||
email: () => false,
|
||||
},
|
||||
);
|
||||
target: "_blank",
|
||||
rel: "nofollow noopener noreferrer",
|
||||
});
|
||||
} else {
|
||||
htmlContent = "";
|
||||
}
|
||||
|
|
|
|||
Loading…
Reference in a new issue