Rescue errors when the postgres adapter isn't in use (h/t to subdigital)
This commit is contained in:
parent
adffbb682f
commit
0b5075a741
@ -1,6 +1,7 @@
|
|||||||
module SilentPostgres
|
module SilentPostgres
|
||||||
def self.init!
|
def self.init!
|
||||||
ActiveRecord::ConnectionAdapters::PostgreSQLAdapter.send(:include, SilentPostgres)
|
ActiveRecord::ConnectionAdapters::PostgreSQLAdapter.send(:include, SilentPostgres)
|
||||||
|
rescue NameError
|
||||||
end
|
end
|
||||||
|
|
||||||
if defined?(Rails::Railtie)
|
if defined?(Rails::Railtie)
|
||||||
|
Loading…
Reference in New Issue
Block a user