Commit 66d9f7d895365571e5a26fcb6a39b807a2ff7f77
1 parent
658197fe
Exists in
master
and in
29 other branches
plugins-infra: load extensions with configuration.to_prepare
Showing
1 changed file
with
3 additions
and
1 deletions
Show diff stats
lib/noosfero/plugin.rb
@@ -68,7 +68,9 @@ class Noosfero::Plugin | @@ -68,7 +68,9 @@ class Noosfero::Plugin | ||
68 | end | 68 | end |
69 | 69 | ||
70 | # load extensions | 70 | # load extensions |
71 | - Dir[File.join(dir, 'lib', 'ext', '*.rb')].each {|file| require_dependency file } | 71 | + Rails.configuration.to_prepare do |
72 | + Dir[File.join(dir, 'lib', 'ext', '*.rb')].each {|file| require_dependency file } | ||
73 | + end | ||
72 | 74 | ||
73 | # load class | 75 | # load class |
74 | klass(plugin_name) | 76 | klass(plugin_name) |