File tree 1 file changed +2
-2
lines changed 1 file changed +2
-2
lines changed Original file line number Diff line number Diff line change @@ -800,13 +800,13 @@ def excerpt(comment)
800
800
# Match from a capital letter to the first period, discarding any links, so
801
801
# that we don't end up matching badges in the README
802
802
first_paragraph_match = text . match ( ParagraphExcerptRegexp )
803
- return text [ 0 ...150 ] . gsub ( / \n / , " " ) . squeeze ( " " ) unless first_paragraph_match
803
+ return text [ 0 ...150 ] . tr_s ( " \n " , " " ) . squeeze ( " " ) unless first_paragraph_match
804
804
805
805
extracted_text = first_paragraph_match [ 0 ]
806
806
second_paragraph = first_paragraph_match . post_match . match ( ParagraphExcerptRegexp )
807
807
extracted_text << " " << second_paragraph [ 0 ] if second_paragraph
808
808
809
- extracted_text [ 0 ...150 ] . gsub ( / \n / , " " ) . squeeze ( " " )
809
+ extracted_text [ 0 ...150 ] . tr_s ( " \n " , " " ) . squeeze ( " " )
810
810
end
811
811
812
812
def generate_ancestor_list ( ancestors , klass )
You can’t perform that action at this time.
0 commit comments