lib/license_finder/license/text.rb in license_finder-1.0.0.0-java vs lib/license_finder/license/text.rb in license_finder-1.0.0.1
- old
+ new
@@ -6,9 +6,10 @@
PLACEHOLDERS = /<[^<>]+>/
def self.normalize_punctuation(text)
text.gsub(SPACES, ' ')
.gsub(QUOTES, '"')
+ .strip
end
def self.compile_to_regex(text)
Regexp.new(Regexp.escape(text).gsub(PLACEHOLDERS, '(.*)'))
end