Fixed: class attribute with spaces on pre tags truncated (#7033).

git-svn-id: svn+ssh://rubyforge.org/var/svn/redmine/trunk@4468 e93f8b46-1217-0410-a6f0-8f06a7374b81
This commit is contained in:
Jean-Philippe Lang
2010-12-05 10:09:18 +00:00
parent 7fb0fe2e91
commit 8841ba97c6
2 changed files with 4 additions and 1 deletions
+1 -1
View File
@@ -1078,7 +1078,7 @@ class RedCloth3 < String
line = "<redpre##{ @pre_list.length }>"
first.match(/<#{ OFFTAGS }([^>]*)>/)
tag = $1
$2.to_s.match(/(class\=\S+)/i)
$2.to_s.match(/(class\=("[^"]+"|'[^']+'))/i)
tag << " #{$1}" if $1
@pre_list << "<#{ tag }>#{ aftertag }"
end