lib/princely/pdf.rb in princely-2.0.0 vs lib/princely/pdf.rb in princely-2.0.1
- old
+ new
@@ -1,10 +1,10 @@
require 'timeout'
module Princely
class Pdf
- attr_accessor :executable, :style_sheets, :logger, :log_file, :server_flag, :media, :javascript_flag, :timeout, :license_path
+ attr_accessor :executable, :style_sheets, :logger, :log_file, :server_flag, :media, :javascript_flag, :timeout
# Initialize method
#
def initialize(options={})
options = {
@@ -12,18 +12,16 @@
:executable => Princely.executable,
:log_file => nil,
:logger => nil,
:server_flag => true,
:media => nil,
- :javascript_flag => false,
- :license_path => nil
+ :javascript_flag => false
}.merge(options)
@executable = options[:path] ? Princely::Executable.new(options[:path]) : options[:executable]
@style_sheets = ''
@log_file = options[:log_file]
@logger = options[:logger]
- @license_path = options[:license_path]
@server_flag = options[:server_flag]
@media = options[:media]
@javascript_flag = options[:javascript_flag]
@timeout = options[:timeout]
end
@@ -102,10 +100,9 @@
path = exe_path
# Don't spew errors to the standard out...and set up to take IO
# as input and output
path << " --media=#{media}" if media
path << " --silent - -o #{output_file}"
- path << " --license-file=#{}" if license_path
path << " >> '#{log_file}' 2>> '#{log_file}'" if options[:output_to_log_file]
log_command path if options[:log_command]
# Actually call the prince command, and pass the entire data stream back.