Replace XSS filter with sanitize-html
This commit is contained in:
parent
8630c5972c
commit
1c3a669279
3 changed files with 61 additions and 253 deletions
|
|
@ -36,9 +36,11 @@ CustomizationModule.prototype.load = function (data) {
|
|||
|
||||
if ("motd" in data) {
|
||||
this.motd = {
|
||||
motd: data.motd.motd || "",
|
||||
html: data.motd.html || ""
|
||||
motd: data.motd.motd || ""
|
||||
};
|
||||
|
||||
this.motd.motd = XSS.sanitizeHTML(this.motd.motd);
|
||||
this.motd.html = this.motd.motd.replace(/\n/g, "<br>");
|
||||
}
|
||||
};
|
||||
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue