Don't eager load models when the database is offline
This commit is contained in:
parent
b91072bed4
commit
0605d4aa8b
1 changed files with 5 additions and 0 deletions
|
@ -63,5 +63,10 @@ module OpenStreetMap
|
|||
unless STATUS == :database_offline
|
||||
config.active_record.schema_format = :sql
|
||||
end
|
||||
|
||||
# Don't eager load models when the database is offline
|
||||
if STATUS == :database_offline
|
||||
config.paths["app/models"].skip_eager_load!
|
||||
end
|
||||
end
|
||||
end
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue