From 297d608b610f478cda9f1bdf4f80bb1fe7f0a1bc Mon Sep 17 00:00:00 2001 From: Xavi Nguyen Date: Mon, 1 Jan 2018 20:07:58 -0800 Subject: [PATCH] Fix issue when report step is empty --- magmi/engines/magmi_productimportengine.php | 10 +++++++--- 1 file changed, 7 insertions(+), 3 deletions(-) diff --git a/magmi/engines/magmi_productimportengine.php b/magmi/engines/magmi_productimportengine.php index cf0070aa..0bf567f0 100755 --- a/magmi/engines/magmi_productimportengine.php +++ b/magmi/engines/magmi_productimportengine.php @@ -1130,10 +1130,14 @@ public function processDataSourceLine($item, $rstep, &$tstart, &$tdiff, &$lastdb $res = array("ok" => 0, "last" => 0); $canceled = false; $this->_current_row++; - if ($this->_current_row % $rstep == 0) - { - $this->reportStats($this->_current_row, $tstart, $tdiff, $lastdbtime, $lastrec); + + if ($rstep > 0) { + if ($this->_current_row % $rstep == 0) + { + $this->reportStats($this->_current_row, $tstart, $tdiff, $lastdbtime, $lastrec); + } } + try { if (is_array($item) && count($item) > 0)