From 0bb18b3a0afd89783bec25a1d73bb6107222ed21 Mon Sep 17 00:00:00 2001 From: Maxime Bourget Date: Sat, 15 Jun 2013 21:11:38 +0100 Subject: [PATCH] Fix hook not trigger on purchase order cart. --- hooks.php | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/hooks.php b/hooks.php index 026f2d2..6922792 100644 --- a/hooks.php +++ b/hooks.php @@ -137,7 +137,7 @@ class hooks_order_line_extra extends hooks { } function db_postwrite($cart, $trans_type) { - if(is_a($cart, "Cart")) { + if(is_a($cart, "Cart") || is_a($cart, "purch_order")) { // It's a cart. Find all the stock_id and update the cache table foreach($cart->line_items as $line_no => $item) { -- 2.30.2