attachment_fu icon indicating copy to clipboard operation
attachment_fu copied to clipboard

Files not properly "required"

Open tricon opened this issue 16 years ago • 0 comments

When using attachment_fu alongside Yard, launching the Rails server throws an error that constant Technoweenie::AttachmentFu can not be found. It is failing on:

ActiveRecord::Base.send(:extend, Technoweenie::AttachmentFu::ActMethods)

When using attachment_fu alongside Shoulda, the same error is thrown when attempting to run tests.

In "init.rb", only TempFile and Geometry are required. Adding the following resolves the aforementioned issue, and should be added to the repo:

require 'technoweenie/attachment_fu'
Dir.glob(File.join(File.dirname(__FILE__), 'lib/backends/*.rb')).each {|f| require f }
Dir.glob(File.join(File.dirname(__FILE__), 'lib/processors/*.rb')).each {|f| require f }

tricon avatar Jul 22 '09 17:07 tricon