Fixed variant deletion bug
This commit is contained in:
1 parent
95e9b97abe
commit
27ca264d23
1 file changed
+1
-1
@@ -14,7 +14,7 @@ Spree::Variant.class_eval do
|
|||||||
# We need to delete the Digital manually here as soon as the Variant is nullified.
|
# 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.
|
# Otherwise you'll have orphan Digitals (and their attached files!) associated with unused Variants.
|
||||||
def destroy_digital
|
def destroy_digital
|
||||||
digital.destroy
|
digitals.map &:destroy
|
||||||
end
|
end
|
||||||
|
|
||||||
end
|
end
|
||||||
Reference in new issue
Block a user