Node.js based forum software built for the modern web
fix: remove optional
Barış Soner Uşaklı20e751f0e85e
diff --git a/src/topics/posts.js b/src/topics/posts.jsindex 6b4473f361..1e8526f0a6 100644--- a/src/topics/posts.js+++ b/src/topics/posts.js@@ -14,7 +14,7 @@ const plugins = require('../plugins');const utils = require('../utils');const privileges = require('../privileges');-const backlinkRegex = new RegExp(`(?:${nconf.get('url').replace('/', '\\/')}|\b|\\s)\\/topic\\/([a-fA-F0-9-]+)(?=\\/|$|\\s)?`, 'g');+const backlinkRegex = new RegExp(`(?:${nconf.get('url').replace('/', '\\/')}|\b|\\s)\\/topic\\/([a-fA-F0-9-]+)(?=\\/|$|\\s)`, 'g');module.exports = function (Topics) {Topics.onNewPostMade = async function (postData) {