Skip to content

Commit 7580b96

Browse files
committed
RUBOOOOOOOcOOOooOOP
1 parent 7efffc4 commit 7580b96

File tree

1 file changed

+2
-2
lines changed

1 file changed

+2
-2
lines changed

lib/discourse_translator/content_splitter.rb

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -59,10 +59,10 @@ def self.extract_mixed_chunk(text, size: CHUNK_SIZE)
5959
end
6060

6161
def self.find_nearest_html_end_index(text, target_pos)
62-
return nil unless text.include?("<")
62+
return nil if !text.include?("<")
6363

6464
begin
65-
doc = Nokogiri::HTML.fragment(text)
65+
doc = Nokogiri::HTML5.fragment(text)
6666
current_length = 0
6767

6868
doc.children.each do |node|

0 commit comments

Comments
 (0)