Am 12.12.2007 um 21:23 schrieb Artūras Šlajus:
> i wasn't talking about those, i was talking about
> vendor/plugins/your_plugin/app/models/foo.rb (same with controllers)
Yes, like I said in the other mail I mistakenly looked at an outdated
version. You're right that this isn't going to work by default.
> It used to work perfectly with 1.2, now it just loads them once :(
That might have to do with the fact that Engines now uses the new
plugin architecture that's implemented in Rails 2.0 rather than
shipping it's own stuff.
Rails makes it so that your plugin load paths are added to
Dependencies.load_once_paths which means that those classes aren't
reloaded.
You can remove them from there, though:
# somewhere
Rails::Plugin.class_eval do
def reloadable!
load_paths.each { |p| Dependencies.load_once_paths.delete(p) }
end
end
# in your plugin init.rb
reloadable!
--
sven fuchs [EMAIL PROTECTED]
artweb design http://www.artweb-design.de
grünberger 65 + 49 (0) 30 - 47 98 69 96 (phone)
d-10245 berlin + 49 (0) 171 - 35 20 38 4 (mobile)
_______________________________________________
Engine-Developers mailing list
[email protected]
http://lists.rails-engines.org/listinfo.cgi/engine-developers-rails-engines.org