lib/green_monkey/railtie.rb in green_monkey-0.1.3 vs lib/green_monkey/railtie.rb in green_monkey-0.1.4
- old
+ new
@@ -1,15 +1,16 @@
# coding: utf-8
module GreenMonkey
class Railtie < Rails::Railtie
- initializer "load extentions and patches" do
+ initializer 'green_monkey.init', :before => :load_config_initializers do
require "green_monkey/ext/active_model"
ActiveModel::Dirty.send :include, GreenMonkey::ModelHelpers
-
+ ActiveRecord::Base.send :include, GreenMonkey::ModelHelpers
+
require 'green_monkey/ext/view_helper'
ActionView::Base.send :include, GreenMonkey::ViewHelper
-
+
require "green_monkey/ext/action_view"
require "green_monkey/ext/haml"
require "green_monkey/ext/mida"
end
end
\ No newline at end of file