encoded_attachment 0.1.4 → 0.1.5

Sign up to get free protection for your applications and to get access to all the features.
@@ -1,3 +1,3 @@
1
1
  module EncodedAttachment
2
- VERSION = "0.1.4"
2
+ VERSION = "0.1.5"
3
3
  end
@@ -34,6 +34,12 @@ if defined?(Rails::Railtie)
34
34
  ActiveSupport.on_load(:active_resource) do
35
35
  EncodedAttachment.setup_activeresource
36
36
  end
37
+
38
+ ActiveSupport.on_load(:before_initialize) do
39
+ # workaround until above load hook works
40
+ EncodedAttachment.setup_activeresource \
41
+ unless !defined?(ActiveResource) || ActiveResource::Base.methods.include?('has_encoded_attachment')
42
+ end
37
43
  else
38
44
  # Load right away if required outside of Rails initialization
39
45
  EncodedAttachment.setup_activerecord if defined?(ActiveRecord)
metadata CHANGED
@@ -1,13 +1,13 @@
1
1
  --- !ruby/object:Gem::Specification
2
2
  name: encoded_attachment
3
3
  version: !ruby/object:Gem::Version
4
- hash: 19
4
+ hash: 17
5
5
  prerelease: false
6
6
  segments:
7
7
  - 0
8
8
  - 1
9
- - 4
10
- version: 0.1.4
9
+ - 5
10
+ version: 0.1.5
11
11
  platform: ruby
12
12
  authors:
13
13
  - Nick Ragaz
@@ -15,7 +15,7 @@ autorequire:
15
15
  bindir: bin
16
16
  cert_chain: []
17
17
 
18
- date: 2010-06-06 00:00:00 -04:00
18
+ date: 2010-06-07 00:00:00 -04:00
19
19
  default_executable:
20
20
  dependencies:
21
21
  - !ruby/object:Gem::Dependency