mirror of
https://github.com/NodeBB/NodeBB.git
synced 2025-10-31 19:15:58 +01:00
feat: replace relative urls to absolute before sending email notifs
https://github.com/NodeBB/NodeBB/pull/8366/files
This commit is contained in:
@@ -77,7 +77,10 @@ module.exports = function (Posts) {
|
||||
};
|
||||
|
||||
Posts.relativeToAbsolute = function (content, regex) {
|
||||
// Turns relative links in post body to absolute urls
|
||||
// Turns relative links in content to absolute urls
|
||||
if (!content) {
|
||||
return content;
|
||||
}
|
||||
var parsed;
|
||||
var current = regex.regex.exec(content);
|
||||
var absolute;
|
||||
|
||||
Reference in New Issue
Block a user