diff --git a/db/seeds.rb b/db/seeds.rb index 34e812799b..d54987f68f 100644 --- a/db/seeds.rb +++ b/db/seeds.rb @@ -50,3 +50,6 @@ def create_mail_method end create_mail_method + +spree_user = Spree::User.first +spree_user && spree_user.confirm! diff --git a/lib/tasks/dev.rake b/lib/tasks/dev.rake index 84d51466d3..6fa9af6f3e 100644 --- a/lib/tasks/dev.rake +++ b/lib/tasks/dev.rake @@ -9,7 +9,6 @@ namespace :openfoodnetwork do require_relative '../../spec/support/spree/init' task_name = "openfoodnetwork:dev:load_sample_data" - spree_user = Spree::User.find_by_email('spree@example.com') country = Spree::Country.find_by_iso(ENV.fetch('DEFAULT_COUNTRY_CODE')) state = country.states.first @@ -202,8 +201,6 @@ namespace :openfoodnetwork do CreateOrderCycle.new(enterprise2, variants).call EnterpriseRole.create!(user: Spree::User.first, enterprise: enterprise2) - - spree_user.confirm! end end end