mailfakk2 0.2.1 → 0.2.2

Sign up to get free protection for your applications and to get access to all the features.
Files changed (3) hide show
  1. data/bin/mailfakk2 +4 -2
  2. data/lib/facsimile.rb +3 -2
  3. metadata +2 -2
@@ -7,6 +7,8 @@ include Logging
7
7
  begin
8
8
  fakk = MailFakk2.deliver!(STDIN)
9
9
  rescue Exception => e
10
- log(e.message, :err)
11
- STDERR.puts e.message
10
+ message = "Could not send fax: #{e.message}"
11
+ log(message, :err)
12
+ log(e.backtrace.inspect, :err)
13
+ STDERR.puts message
12
14
  end
@@ -130,8 +130,9 @@ class Facsimile
130
130
 
131
131
  def pdfdata2tiff(source_data)
132
132
  pdf = mktemp('pdf')
133
- pdf.puts source_data
134
- pdf.close
133
+ File.open pdf.path, 'w' do |f|
134
+ f.puts source_data
135
+ end
135
136
  pdf2tiff(pdf.path)
136
137
  end
137
138
 
metadata CHANGED
@@ -5,8 +5,8 @@ version: !ruby/object:Gem::Version
5
5
  segments:
6
6
  - 0
7
7
  - 2
8
- - 1
9
- version: 0.2.1
8
+ - 2
9
+ version: 0.2.2
10
10
  platform: ruby
11
11
  authors:
12
12
  - Niklas Hofer