From a0d475720b159f63da593af0462f11a36a564910 Mon Sep 17 00:00:00 2001 From: wangyidong Date: Tue, 5 Jan 2016 15:22:04 +0800 Subject: [PATCH] * fix error. --- module/branch/model.php | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/module/branch/model.php b/module/branch/model.php index f43773ae72..3af5aa6618 100644 --- a/module/branch/model.php +++ b/module/branch/model.php @@ -43,7 +43,7 @@ class branchModel extends model if(strpos($params, 'noempty') === false) { $product = $this->loadModel('product')->getById($productID); - if($product->type == 'normal') return array(); + if(!$product or $product->type == 'normal') return array(); $branches = array('0' => $this->lang->branch->all . $this->lang->product->branchName[$product->type]) + $branches; }