diff options
-rw-r--r-- | lib/redcloth3.rb | 2 | ||||
-rw-r--r-- | test/unit/helpers/application_helper_test.rb | 1 |
2 files changed, 2 insertions, 1 deletions
diff --git a/lib/redcloth3.rb b/lib/redcloth3.rb index 220617f14..7898d721f 100644 --- a/lib/redcloth3.rb +++ b/lib/redcloth3.rb @@ -341,7 +341,7 @@ class RedCloth3 < String A_HLGN = /(?:(?:<>|<|>|\=|[()]+)+)/ A_VLGN = /[\-^~]/ C_CLAS = '(?:\([^)]+\))' - C_LNGE = '(?:\[[^\]]+\])' + C_LNGE = '(?:\[[^\[\]]+\])' C_STYL = '(?:\{[^}]+\})' S_CSPN = '(?:\\\\\d+)' S_RSPN = '(?:/\d+)' diff --git a/test/unit/helpers/application_helper_test.rb b/test/unit/helpers/application_helper_test.rb index 087d96316..d23300309 100644 --- a/test/unit/helpers/application_helper_test.rb +++ b/test/unit/helpers/application_helper_test.rb @@ -177,6 +177,7 @@ class ApplicationHelperTest < HelperTestCase '[[onlinestore:Unknown page]]' => '<a href="/wiki/onlinestore/Unknown_page" class="wiki-page new">Unknown page</a>', # striked through link '-[[Another page|Page]]-' => '<del><a href="/wiki/ecookbook/Another_page" class="wiki-page">Page</a></del>', + '-[[Another page|Page]] link-' => '<del><a href="/wiki/ecookbook/Another_page" class="wiki-page">Page</a> link</del>', # escaping '![[Another page|Page]]' => '[[Another page|Page]]', } |