lib/ecm/news/engine.rb in ecm_news2-1.2.0 vs lib/ecm/news/engine.rb in ecm_news2-2.0.1
- old
+ new
@@ -1,12 +1,11 @@
module Ecm
module News
class Engine < ::Rails::Engine
initializer :ecm_news_engine do
ActiveAdmin.setup do |config|
- config.load_paths << File.join(self.root, 'app/admin')
+ config.load_paths << File.join(root, 'app', 'admin')
end
- end
+ end if Gem::Specification.find_all_by_name('activeadmin').any?
end
end
end
-