From 501b910e6eb9fd2df99f9348159ea74532f835db Mon Sep 17 00:00:00 2001 From: vAugagneur Date: Wed, 22 Feb 2012 10:40:47 +0000 Subject: [PATCH] //small bug --- admin-dev/ajax.php | 6 +++--- 1 file changed, 3 insertions(+), 3 deletions(-) diff --git a/admin-dev/ajax.php b/admin-dev/ajax.php index a151f99d4..cfc707e4c 100644 --- a/admin-dev/ajax.php +++ b/admin-dev/ajax.php @@ -671,14 +671,14 @@ if (Tools::isSubmit('syncImapMail')) $errors = imap_errors(); $str_errors = ''; $str_error_delete = ''; - if (sizeof($errors)) + if (sizeof($errors) && is_array($errors)) { - $str_errors = '["'; + var_dump($errors); + $str_errors = ''; foreach($errors as $error) $str_errors .= '"'.$error.'",'; $str_errors = rtrim($str_errors, ',').''; } - //checks if imap connexion is active if (!$mbox) die('{"hasError" : true, "errors" : ["Cannot connect to the mailbox"]}');