Filter EOT characters from import
This commit is contained in:
		
							parent
							
								
									ede3baae64
								
							
						
					
					
						commit
						201233f89f
					
				@ -16,7 +16,7 @@ module WordPressImport
 | 
			
		||||
        puts "WARNING: LibXML by default supports 10MB max file size. On some systems your file will be silently truncated; on others, an error will be raised. Consider splitting your file into smaller chunks and running rake tasks individually (authors, then blog/pages, then media), and double-check the import results."
 | 
			
		||||
      end
 | 
			
		||||
 | 
			
		||||
      @doc = Nokogiri::XML(file)
 | 
			
		||||
      @doc = Nokogiri::XML(file.read().gsub("\u0004", "")) # get rid of all EOT characters
 | 
			
		||||
    end
 | 
			
		||||
 | 
			
		||||
    def authors
 | 
			
		||||
 | 
			
		||||
		Loading…
	
	
			
			x
			
			
		
	
		Reference in New Issue
	
	Block a user