##// END OF EJS Templates
Merged r15607 (#23246)....
Jean-Philippe Lang -
r15233:e35c8f7e2ec2
parent child
Show More
@@ -23,7 +23,7 module Redmine
23 23 def uri_with_safe_scheme?(uri, schemes = ['http', 'https', 'ftp', 'mailto', nil])
24 24 # URLs relative to the current document or document root (without a protocol
25 25 # separator, should be harmless
26 return true unless uri.include? ":"
26 return true unless uri.to_s.include? ":"
27 27
28 28 # Other URLs need to be parsed
29 29 schemes.include? URI.parse(uri).scheme
@@ -28,6 +28,10 class Redmine::WikiFormatting::MarkdownFormatterTest < ActionView::TestCase
28 28 assert @formatter.new("!>[](foo.png)").to_html
29 29 end
30 30
31 def test_empty_image_should_not_raise_exception
32 assert @formatter.new("![]()").to_html
33 end
34
31 35 # re-using the formatter after getting above error crashes the
32 36 # ruby interpreter. This seems to be related to
33 37 # https://github.com/vmg/redcarpet/issues/318
General Comments 0
You need to be logged in to leave comments. Login now