public
Description: Treat an ActiveRecord model as a file attachment, storing its patch, size, content type, etc.
Homepage: http://weblog.techno-weenie.net
Clone URL: git://github.com/technoweenie/attachment_fu.git
Click here to lend your support to: attachment_fu and make a donation at www.pledgie.com !
Reapplied patch that was accidentally reverted during recent merges
(Ticket #20: 
http://ar-code.lighthouseapp.com/projects/35-attachment_fu/tickets/20)
rmm5t (author)
Fri Mar 14 10:56:54 -0700 2008
commit  72dae44d43181f382bcec3f1894f22abadba3d4f
tree    8192aea642d37d8fdd227e459f5a0e5dcf88ce96
parent  90d3e81793f2741c9cf0cdf28e9403e804486e93
...
72
73
74
75
 
76
77
78
...
72
73
74
 
75
76
77
78
0
@@ -72,7 +72,7 @@ module Technoweenie # :nodoc:
0
         with_options :foreign_key => 'parent_id' do |m|
0
           m.has_many :thumbnails, :class_name => attachment_options[:thumbnail_class].to_s
0
           m.belongs_to :parent, :class_name => base_class.to_s
0
- end
0
+ end unless options[:thumbnails].empty?
0
 
0
         storage_mod = Technoweenie::AttachmentFu::Backends.const_get("#{options[:storage].to_s.classify}Backend")
0
         include storage_mod unless included_modules.include?(storage_mod)

Comments

    No one has commented yet.