lib/rtesseract/pdf.rb in rtesseract-3.1.0 vs lib/rtesseract/pdf.rb in rtesseract-3.1.1

- old
+ new

@@ -5,11 +5,11 @@ extend Base def self.run(source, errors, options) options.tessedit_create_pdf = 1 - RTesseract::Command.new(source, temp_file, errors, options).run - - File.open(temp_file('.pdf'), 'r') + RTesseract::Command.new(source, temp_file_path, errors, options).run do |output_path| + File.open("#{output_path}.pdf", 'r') + end end end end