Created
January 21, 2014 21:40
-
-
Save canadaduane/8548959 to your computer and use it in GitHub Desktop.
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
# lib/account_with_account_domains.rb: | |
Account.class_eval do | |
# ... | |
end | |
# init.rb: | |
configure_method = Proc.new do | |
::ApplicationController.promote_view_path File.dirname(__FILE__)+'/app/views' | |
require_dependency 'account_with_account_domains' | |
end | |
if CANVAS_RAILS2 | |
Rails.configuration.to_prepare(&configure_method) | |
else | |
class MyPluginRailtie < Rails::Railtie; end | |
MyPluginRailtie.config.to_prepare(&configure_method) | |
end |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment