autotelik / datashift_spree

Comprehensive import and export tools for Spree and Spree Products
Other
90 stars 104 forks source link

Fixes shopify order addresses to pull user addresses if not available on... #41

Closed prachetasp closed 9 years ago

prachetasp commented 9 years ago

... order and fixes address population logic

What's this PR do?

The order migration logic lacked proper support for populating addresses. The long-term fix is to pull the address information from the shopify export but the quick fix is to pull it from the User model directly. The if-else logic for populating addresses was also faulty and caused silent exceptions which caused a new (usually duplicate) address to be created when the order was saved (not sure how this was even possible...)