Merge branch 'master' of github.com:alchemy-fr/Phraseanet

This commit is contained in:
Romain Neutron
2011-12-26 17:26:37 +01:00
6 changed files with 62 additions and 4 deletions

View File

@@ -397,7 +397,7 @@ class User_Adapter implements User_Interface, cache_cacheableInterface
*/
public function set_email($email)
{
if (!trim($email))
if (trim($email) == '')
$email = null;
$test_user = User_Adapter::get_usr_id_from_email($email);
@@ -878,6 +878,9 @@ class User_Adapter implements User_Interface, cache_cacheableInterface
public static function get_usr_id_from_email($email)
{
if(is_null($email))
return false;
$conn = connection::getPDOConnection();
$sql = 'SELECT usr_id FROM usr
WHERE usr_mail = :email

View File

@@ -57,7 +57,7 @@ class task_period_emptyColl extends task_appboxAbstract
$collection = collection::get_from_base_id($this->base_id);
$this->total_records = $collection->get_record_amount();
$collection->empty_collection(200);
$this->records_done +=200;
$this->records_done += $this->total_records;
$this->setProgress($this->records_done, $this->total_records);
if ($this->total_records == 0)