[-][-] FO : not check if Object employee is Load

git-svn-id: http://dev.prestashop.com/svn/v1/branches/1.5.x@9173 b9a71923-0436-4b27-9f14-aed3839534dd
This commit is contained in:
lLefevre committed 2011-10-10 09:18:11 +00:00
1 parent 493dc1d811
commit 791dd3e6a6
1 file changed
+2 -2
+2 -2
View File
@@ -379,8 +379,8 @@ class ShopCore extends ObjectModel
$employee = Context::getContext()->employee; $employee = Context::getContext()->employee;
/* if the profile isn't a superAdmin */ // If the profile isn't a superAdmin
if ($employee && $employee->id_profile != _PS_ADMIN_PROFILE_) if (Validate::isLoadedObject($employee) && $employee->id_profile != _PS_ADMIN_PROFILE_)
{ {
$select .= ', es.id_employee'; $select .= ', es.id_employee';
$from .= 'LEFT JOIN '._DB_PREFIX_.'employee_shop es ON es.id_shop = s.id_shop'; $from .= 'LEFT JOIN '._DB_PREFIX_.'employee_shop es ON es.id_shop = s.id_shop';