From 7185af32fce36fae3db01610e634081a11f48568 Mon Sep 17 00:00:00 2001 From: Jacques Distler Date: Wed, 9 Sep 2009 15:01:25 -0500 Subject: [PATCH] Fix an Eyesore That just looked sloppy. I blame copy/paste. --- lib/stringsupport.rb | 3 +-- 1 file changed, 1 insertion(+), 2 deletions(-) diff --git a/lib/stringsupport.rb b/lib/stringsupport.rb index cb70ea33..c640f8d7 100644 --- a/lib/stringsupport.rb +++ b/lib/stringsupport.rb @@ -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(