Lately, I have been using the next initializer in a Rails 5 project:
initializers/initialize_configs.rb
$current_city = Config.first.city
But after a few changes, I had to rails db:migrate and rails db:seed and then, I got this error. Until that point, my application worked well.
Config is a one-row only table in which I save configs for each VPS, and $current_city is also a var the each VPS has.
The problem is that this error show up when I do rails db:seed, and so I cant load my initial configuration.
How could I fix the problem while still loading this initial dalta?