Skip to content

Commit

Permalink
Should use app.paths instead of specific path.
Browse files Browse the repository at this point in the history
  • Loading branch information
kennyj committed Oct 8, 2012
1 parent 800604e commit 4756ced
Showing 1 changed file with 2 additions and 1 deletion.
3 changes: 2 additions & 1 deletion activerecord/lib/active_record/railtie.rb
Original file line number Diff line number Diff line change
Expand Up @@ -129,7 +129,8 @@ class Railtie < Rails::Railtie # :nodoc:
end

initializer "active_record.add_watchable_files" do |app|
config.watchable_files.concat ["#{app.root}/db/schema.rb", "#{app.root}/db/structure.sql"]
path = app.paths["db"].first
config.watchable_files.concat ["#{path}/schema.rb", "#{path}/structure.sql"]
end

config.after_initialize do |app|
Expand Down

0 comments on commit 4756ced

Please sign in to comment.