Skip to content

Commit aa663a7

Browse files
authored
Merge pull request #106 from zackgilbert/zackgilbert-patch-optional-sqlite3_production_warning
Add conditional check for sqlite3_production_warning before setting to false in railtie.rb
2 parents a01a616 + c01d738 commit aa663a7

File tree

1 file changed

+4
-2
lines changed

1 file changed

+4
-2
lines changed

lib/litestack/railtie.rb

+4-2
Original file line numberDiff line numberDiff line change
@@ -3,8 +3,10 @@
33
module Litestack
44
class Railtie < ::Rails::Railtie
55
initializer :disable_production_sqlite_warning do |app|
6-
# The whole point of this gem is to use sqlite3 in production.
7-
app.config.active_record.sqlite3_production_warning = false
6+
if config.active_record.key?(:sqlite3_production_warning)
7+
# The whole point of this gem is to use sqlite3 in production.
8+
app.config.active_record.sqlite3_production_warning = false
9+
end
810
end
911
end
1012
end

0 commit comments

Comments
 (0)