From fa19bbed4ad96292b0cfc24eb8b023ca2c1eb48c Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?C=C3=A9dric=20Krier?= Date: Wed, 12 Nov 2008 17:26:42 +0100 Subject: [PATCH] Fix infinit loop in copy of product --- product.py | 8 ++++++++ 1 file changed, 8 insertions(+) diff --git a/product.py b/product.py index d9b1c63b43..316db2f03b 100644 --- a/product.py +++ b/product.py @@ -132,4 +132,12 @@ class Product(OSV): return res + def copy(self, cursor, user, product_id, default=None, context=None): + if default is None: + default = {} + default = default.copy() + default['products'] = False + return super(Product, self).copy(cursor, user, product_id, + default=default, context=context) + Product()