Sanitize input to prevent XSS

This commit is contained in:
Alan Friedman 2016-01-12 22:38:31 -05:00
parent 11814aae88
commit dc7ca8b7e7

View File

@ -191,7 +191,7 @@ $(function() {
// Prevents input from having injected markup
function cleanInput (input) {
var message = $('<div/>').text(input).text();
var message = $('<div/>').html(input).text();
message = Autolinker.link(message);
return message;
}