Skip to content
Snippets Groups Projects
Commit a4ae696a authored by Nicolas Lempereur's avatar Nicolas Lempereur
Browse files

[FIX] website_sale_wishlist: unlink instead of archive


Since 11.0 88b75f15 the wishlist can't contain duplicates: thus if we
remove an element from wishlist (by adding it to cart or removing) there
is an error next times it is added (since the product is already in
wishlist but archived until next garbage collection).

opw-2074843
closes #37235

Signed-off-by: default avatarNicolas Lempereur (nle) <nle@odoo.com>
parent 8fb923f1
No related branches found
No related tags found
No related merge requests found
......@@ -42,5 +42,5 @@ class WebsiteSaleWishlist(WebsiteSale):
@http.route(['/shop/wishlist/remove/<model("product.wishlist"):wish>'], type='json', auth="public", website=True)
def rm_from_wishlist(self, wish, **kw):
wish.active = False
wish.sudo().unlink()
return True
0% Loading or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment