Fix CSS injection
This commit is contained in:
parent
a6cdf714a6
commit
6a43248cb3
7 changed files with 14 additions and 5 deletions
|
@ -1,4 +1,10 @@
|
|||
module ApplicationHelper
|
||||
include SanitizeUrl
|
||||
|
||||
def sanitize_url(url)
|
||||
super(url, schemes: ['http', 'https'], replace_evil_with: root_url)
|
||||
end
|
||||
|
||||
def flash_class(level)
|
||||
case level
|
||||
when "notice" then "alert-success"
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue