When deleting an order with uc_order_delete(), It looks like the uc_order module does not call field_attach_delete() to delete any additional field values the order might have already.

I will attach a patch suggestion shortly.

CommentFileSizeAuthor
#2 deleting_an_order_does-2625346-2.patch922 bytesayesh

Comments

Ayesh created an issue. See original summary.

ayesh’s picture

Status: Active » Needs review
StatusFileSize
new922 bytes

Attaching a patch. It simply calls field_attach_delete on the order that is already loaded. I would be really grateful if you could review when you have some time.

Thanks.

  • longwave committed 0ef1a97 on 7.x-3.x authored by Ayesh
    Issue #2625346 by Ayesh: Deleting an order does not delete associated...
longwave’s picture

Status: Needs review » Fixed

Yes, this makes perfect sense. We call all the other field_attach_* functions, except for this one.

Committed, with a fix to the indentation. Thanks for the patch!

This change is not needed in 8.x-4.x as the entity storage base class already takes care of deleting fields.

ayesh’s picture

Great. Thanks a lot Dave :)

Status: Fixed » Closed (fixed)

Automatically closed - issue fixed for 2 weeks with no activity.