diff --git a/core/lib/Thelia/Core/HttpFoundation/Session/Session.php b/core/lib/Thelia/Core/HttpFoundation/Session/Session.php
index f2eaadc4d..00fb7974b 100755
--- a/core/lib/Thelia/Core/HttpFoundation/Session/Session.php
+++ b/core/lib/Thelia/Core/HttpFoundation/Session/Session.php
@@ -164,10 +164,12 @@ class Session extends BaseSession
$cart = null;
if ($cart_id) {
$cart = CartQuery::create()->findPk($cart_id);
- try {
- $this->verifyValidCart($cart);
- } catch (InvalidCartException $e) {
- $cart = null;
+ if($cart) {
+ try {
+ $this->verifyValidCart($cart);
+ } catch (InvalidCartException $e) {
+ $cart = null;
+ }
}
}
diff --git a/core/lib/Thelia/Core/Template/Element/BaseI18nLoop.php b/core/lib/Thelia/Core/Template/Element/BaseI18nLoop.php
index 35077f5c4..283aad797 100644
--- a/core/lib/Thelia/Core/Template/Element/BaseI18nLoop.php
+++ b/core/lib/Thelia/Core/Template/Element/BaseI18nLoop.php
@@ -73,7 +73,7 @@ abstract class BaseI18nLoop extends BaseLoop
$columns,
$foreignTable,
$foreignKey,
- $forceReturn
+ $this->getForce_return()
);
}
}
diff --git a/core/lib/Thelia/Core/Template/Element/BaseLoop.php b/core/lib/Thelia/Core/Template/Element/BaseLoop.php
index b684d06e2..5ac23142d 100755
--- a/core/lib/Thelia/Core/Template/Element/BaseLoop.php
+++ b/core/lib/Thelia/Core/Template/Element/BaseLoop.php
@@ -89,6 +89,7 @@ abstract class BaseLoop
Argument::createIntTypeArgument('page'),
Argument::createIntTypeArgument('limit', PHP_INT_MAX),
Argument::createBooleanTypeArgument('backend_context', false),
+ Argument::createBooleanTypeArgument('force_return', false),
);
}
diff --git a/templates/default/index.html b/templates/default/index.html
index 39205497c..6feaf9b81 100644
--- a/templates/default/index.html
+++ b/templates/default/index.html
@@ -40,7 +40,7 @@
{ifloop rel="image_product_new" }
@@ -99,7 +99,7 @@
{ifloop rel="image_product_promo" }