Fixed variant deletion bug

This commit is contained in:
Michael Bianco
2012-07-15 23:14:25 -03:00
parent 95e9b97abe
commit 27ca264d23

View File

@@ -14,7 +14,7 @@ Spree::Variant.class_eval do
# We need to delete the Digital manually here as soon as the Variant is nullified.
# Otherwise you'll have orphan Digitals (and their attached files!) associated with unused Variants.
def destroy_digital
digital.destroy
digitals.map &:destroy
end
end