Files
openfoodnetwork/lib
Matt-Yorkley 7e9bf43ec8 Guard against calls to the database during db:create
Rails 5.2 has changed the way initializers are called during certain rake tasks including `db:create`. Initializers that were previously not loaded are now loaded (basically the whole app is loaded). This means any calls to #table_exists? that appear in the app will throw fatal errors as the database doesn't exist yet during that task, but those calls are made before `db:create` has even started, which means the database can't be created.

There are also a few other places in Spree code where #table_exists? is called, and they already call #connected? first to guard against this issue.
2021-04-08 12:12:37 -07:00
..
2012-03-27 10:10:26 +11:00
2020-06-22 17:39:20 +01:00
2021-03-28 17:33:55 +01:00