Skip to content

Commit

Permalink
Fix for sqlite
Browse files Browse the repository at this point in the history
  • Loading branch information
coorasse committed Nov 26, 2024
1 parent 74ed11d commit 6a29f3f
Showing 1 changed file with 2 additions and 1 deletion.
3 changes: 2 additions & 1 deletion lib/moirai/engine.rb
Original file line number Diff line number Diff line change
Expand Up @@ -12,7 +12,8 @@ class Engine < ::Rails::Engine
I18n.original_backend = I18n.backend
table_created =
begin
ActiveRecord::Base.connection.table_exists?("moirai_translations")
ActiveRecord::Base.connection.is_a?(ActiveRecord::ConnectionAdapters::SQLite3Adapter) ||
ActiveRecord::Base.connection.table_exists?("moirai_translations")
rescue ActiveRecord::NoDatabaseError
false
end
Expand Down

0 comments on commit 6a29f3f

Please sign in to comment.