spree
spree copied to clipboard
FIX: data inside rake db:migrate sometimes not accurate
.where
with .first_or_create
inside .map
sometime fails when create instance for multi-tenant use and main DB loaded and has increased network delay or etc.
In this fix I create array of hashes and then create all records using one sql request.
Manage this branch in Squash
Test this branch here: https://r3chafix-init-setup-on-slow-ti-0k4xi.squash.io
@r3cha can you also fix issues pointed out by CodeClimate ?