[-] MO : fixed editorial issue when the entity does not exist yet for a shop #PSCFV-9442

This commit is contained in:
Damien Metzger
2013-06-13 10:31:39 +02:00
parent a4e6ddf29c
commit e4535e892d
+1 -4
View File
@@ -68,10 +68,7 @@ class EditorialClass extends ObjectModel
static public function getByIdShop($id_shop)
{
$id = Db::getInstance()->getValue('SELECT `id_editorial` FROM `'._DB_PREFIX_.'editorial` WHERE `id_shop` ='.(int)$id_shop);
if ($id)
return new EditorialClass((int)$id);
else
return false;
return new EditorialClass($id);
}
public function copyFromPost()