bteitelb-paperclip 2.3.1.4 → 2.3.1.5
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- data/lib/paperclip/storage.rb +7 -2
- metadata +3 -3
data/lib/paperclip/storage.rb
CHANGED
|
@@ -190,8 +190,13 @@ module Paperclip
|
|
|
190
190
|
def to_file style = default_style
|
|
191
191
|
return @queued_for_write[style] if @queued_for_write[style]
|
|
192
192
|
file = Tempfile.new(path(style))
|
|
193
|
-
|
|
194
|
-
|
|
193
|
+
begin
|
|
194
|
+
file.write(AWS::S3::S3Object.value(path(style), bucket_name))
|
|
195
|
+
file.rewind
|
|
196
|
+
rescue AWS::S3::ResponseError => e
|
|
197
|
+
log("Unexpected error #{e.class} for #{self.class} (id=#{self.id})")
|
|
198
|
+
return nil
|
|
199
|
+
end
|
|
195
200
|
return file
|
|
196
201
|
end
|
|
197
202
|
|
metadata
CHANGED
|
@@ -1,7 +1,7 @@
|
|
|
1
1
|
--- !ruby/object:Gem::Specification
|
|
2
2
|
name: bteitelb-paperclip
|
|
3
3
|
version: !ruby/object:Gem::Version
|
|
4
|
-
version: 2.3.1.
|
|
4
|
+
version: 2.3.1.5
|
|
5
5
|
platform: ruby
|
|
6
6
|
authors:
|
|
7
7
|
- Jon Yurek
|
|
@@ -9,7 +9,7 @@ autorequire:
|
|
|
9
9
|
bindir: bin
|
|
10
10
|
cert_chain: []
|
|
11
11
|
|
|
12
|
-
date: 2009-
|
|
12
|
+
date: 2009-10-25 00:00:00 -07:00
|
|
13
13
|
default_executable:
|
|
14
14
|
dependencies:
|
|
15
15
|
- !ruby/object:Gem::Dependency
|
|
@@ -114,7 +114,7 @@ requirements:
|
|
|
114
114
|
rubyforge_project: paperclip
|
|
115
115
|
rubygems_version: 1.3.4
|
|
116
116
|
signing_key:
|
|
117
|
-
specification_version:
|
|
117
|
+
specification_version: 3
|
|
118
118
|
summary: File attachments as attributes for ActiveRecord
|
|
119
119
|
test_files: []
|
|
120
120
|
|