Fix an Eyesore

That just looked sloppy. I blame copy/paste.
This commit is contained in:
Jacques Distler 2009-09-09 15:01:25 -05:00
parent 3ff68ef42f
commit 7185af32fc

View file

@ -16,8 +16,7 @@ class String
def check_ncrs
text = gsub(/&#[xX]([a-fA-F0-9]+);/) { |m| [$1.hex].pack('U*') =~ UTF8_REGEX ? m : '' }
text.gsub!(/&#(\d+);/) { |m| [$1.to_i].pack('U*') =~ UTF8_REGEX ? m : '' }
text
text.gsub(/&#(\d+);/) { |m| [$1.to_i].pack('U*') =~ UTF8_REGEX ? m : '' }
end
UTF8_REGEX = /\A(