From: Jean-Philippe Lang Date: Wed, 3 Oct 2007 18:00:50 +0000 (+0000) Subject: Fixed: URL with ~ broken in wiki formatting. X-Git-Tag: 0.6.0~86 X-Git-Url: https://source.dussan.org/?a=commitdiff_plain;h=586231067bb1aa0ab7c1da005a6b62413ca0fd2d;p=redmine.git Fixed: URL with ~ broken in wiki formatting. All RedCloth quick phrase modifiers are now limited to a single line. git-svn-id: http://redmine.rubyforge.org/svn/trunk@796 e93f8b46-1217-0410-a6f0-8f06a7374b81 --- diff --git a/lib/redcloth.rb b/lib/redcloth.rb index c4b504871..ae70db747 100644 --- a/lib/redcloth.rb +++ b/lib/redcloth.rb @@ -359,16 +359,16 @@ class RedCloth < String ] QTAGS = [ - ['**', 'b'], - ['*', 'strong'], + ['**', 'b', :limit], + ['*', 'strong', :limit], ['??', 'cite', :limit], ['-', 'del', :limit], - ['__', 'i'], + ['__', 'i', :limit], ['_', 'em', :limit], ['%', 'span', :limit], ['+', 'ins', :limit], - ['^', 'sup'], - ['~', 'sub'] + ['^', 'sup', :limit], + ['~', 'sub', :limit] ] QTAGS.collect! do |rc, ht, rtype| rcq = Regexp::quote rc diff --git a/test/unit/helpers/application_helper_test.rb b/test/unit/helpers/application_helper_test.rb index 1da25b6fe..0048ce5b8 100644 --- a/test/unit/helpers/application_helper_test.rb +++ b/test/unit/helpers/application_helper_test.rb @@ -29,6 +29,7 @@ class ApplicationHelperTest < HelperTestCase def test_auto_links to_test = { 'http://foo.bar' => 'http://foo.bar', + 'http://foo.bar/~user' => 'http://foo.bar/~user', 'http://foo.bar.' => 'http://foo.bar.', 'http://foo.bar/foo.bar#foo.bar.' => 'http://foo.bar/foo.bar#foo.bar.', 'www.foo.bar' => 'www.foo.bar',