[-] FO : fixed loop redirect when pagination have 0 product

This commit is contained in:
vAugagneur
2012-12-17 15:25:56 +01:00
parent 9f474669e6
commit 20b87785e3
+1 -1
View File
@@ -867,7 +867,7 @@ class FrontControllerCore extends Controller
$this->context->cookie->nb_item_per_page = $this->n;
$pages_nb = ceil($nbProducts / (int)$this->n);
if ($this->p > $pages_nb)
if ($this->p > $pages_nb && $nbProducts <> 0)
Tools::redirect(self::$link->getPaginationLink(false, false, $this->n, false, $pages_nb, false));
$start = (int)($this->p - $range);