diff --git a/core/lib/Thelia/Coupon/Type/CouponAbstract.php b/core/lib/Thelia/Coupon/Type/CouponAbstract.php index 6d57b0d38..5a434a8cf 100644 --- a/core/lib/Thelia/Coupon/Type/CouponAbstract.php +++ b/core/lib/Thelia/Coupon/Type/CouponAbstract.php @@ -499,4 +499,11 @@ abstract class CouponAbstract implements CouponInterface return $effects; } + + /** + * @inheritdoc + */ + public function clear() { + // Does nothing. Override this function as needed. + } } diff --git a/core/lib/Thelia/Coupon/Type/CouponInterface.php b/core/lib/Thelia/Coupon/Type/CouponInterface.php index a9382749f..d8190f3d7 100644 --- a/core/lib/Thelia/Coupon/Type/CouponInterface.php +++ b/core/lib/Thelia/Coupon/Type/CouponInterface.php @@ -239,4 +239,9 @@ interface CouponInterface */ public function getEffects($data); + /** + * Clear all the data the coupon may have stored, called after an order is completed. + */ + public function clear(); + }