fix xss vuln
This commit is contained in:
@@ -236,7 +236,7 @@
|
|||||||
if (desc.length > 30) {
|
if (desc.length > 30) {
|
||||||
desc = desc.substring(0, 30) + "...";
|
desc = desc.substring(0, 30) + "...";
|
||||||
}
|
}
|
||||||
var $del = $("<del/>").html(desc);
|
var $del = $("<del/>").text(desc);
|
||||||
$ul.append($("<li/>").html($del));
|
$ul.append($("<li/>").html($del));
|
||||||
} else if (text.match(/^ http/)) {
|
} else if (text.match(/^ http/)) {
|
||||||
text = text.substring(1, 1000);
|
text = text.substring(1, 1000);
|
||||||
|
|||||||
@@ -16,7 +16,7 @@
|
|||||||
</div>
|
</div>
|
||||||
<%= f.input :other_names_comma, :hint => "Separate with commas", :as => :text, :label => "Other names" %>
|
<%= f.input :other_names_comma, :hint => "Separate with commas", :as => :text, :label => "Other names" %>
|
||||||
<%= f.input :group_name %>
|
<%= f.input :group_name %>
|
||||||
<%= f.input :url_string, :label => "URLs", :as => :text, :input_html => {:size => "50x5", :value => params.dig(:artist, :url_string) || @artist.url_array.join("\n")} %>
|
<%= f.input :url_string, :label => "URLs", :as => :text, :input_html => {:size => "50x5", :value => params.dig(:artist, :url_string) || @artist.urls.join("\n")} %>
|
||||||
|
|
||||||
<%= dtext_field "artist", "notes" %>
|
<%= dtext_field "artist", "notes" %>
|
||||||
<%= f.button :submit, "Submit" %>
|
<%= f.button :submit, "Submit" %>
|
||||||
|
|||||||
Reference in New Issue
Block a user