mirror of
https://github.com/alchemy-fr/Phraseanet.git
synced 2025-10-10 11:33:17 +00:00
Coding standards
This commit is contained in:
@@ -907,6 +907,7 @@ class User_Adapter implements User_Interface, cache_cacheableInterface
|
|||||||
public static function get_usr_id_from_email($email)
|
public static function get_usr_id_from_email($email)
|
||||||
{
|
{
|
||||||
if (is_null($email))
|
if (is_null($email))
|
||||||
|
|
||||||
return false;
|
return false;
|
||||||
|
|
||||||
$conn = connection::getPDOConnection();
|
$conn = connection::getPDOConnection();
|
||||||
@@ -1277,6 +1278,7 @@ class User_Adapter implements User_Interface, cache_cacheableInterface
|
|||||||
protected function load_preferences()
|
protected function load_preferences()
|
||||||
{
|
{
|
||||||
if ($this->_prefs)
|
if ($this->_prefs)
|
||||||
|
|
||||||
return $this;
|
return $this;
|
||||||
|
|
||||||
$registry = \registry::get_instance();
|
$registry = \registry::get_instance();
|
||||||
@@ -1485,6 +1487,7 @@ class User_Adapter implements User_Interface, cache_cacheableInterface
|
|||||||
{
|
{
|
||||||
$this->load_preferences();
|
$this->load_preferences();
|
||||||
if (isset($this->_prefs[$prop]) && $this->_prefs[$prop] === $value)
|
if (isset($this->_prefs[$prop]) && $this->_prefs[$prop] === $value)
|
||||||
|
|
||||||
return $value;
|
return $value;
|
||||||
|
|
||||||
$ok = true;
|
$ok = true;
|
||||||
@@ -1522,6 +1525,7 @@ class User_Adapter implements User_Interface, cache_cacheableInterface
|
|||||||
$appbox = appbox::get_instance();
|
$appbox = appbox::get_instance();
|
||||||
$session = $appbox->get_session();
|
$session = $appbox->get_session();
|
||||||
if (!$session->is_authenticated())
|
if (!$session->is_authenticated())
|
||||||
|
|
||||||
return;
|
return;
|
||||||
|
|
||||||
$ses_id = $session->get_ses_id();
|
$ses_id = $session->get_ses_id();
|
||||||
@@ -1796,6 +1800,7 @@ class User_Adapter implements User_Interface, cache_cacheableInterface
|
|||||||
public function get_nonce()
|
public function get_nonce()
|
||||||
{
|
{
|
||||||
if ($this->nonce)
|
if ($this->nonce)
|
||||||
|
|
||||||
return $this->nonce;
|
return $this->nonce;
|
||||||
$nonce = false;
|
$nonce = false;
|
||||||
|
|
||||||
|
@@ -542,6 +542,7 @@ class User_Query implements User_QueryInterface
|
|||||||
public function get_total()
|
public function get_total()
|
||||||
{
|
{
|
||||||
if ($this->total)
|
if ($this->total)
|
||||||
|
|
||||||
return $this->total;
|
return $this->total;
|
||||||
|
|
||||||
$conn = $this->appbox->get_connection();
|
$conn = $this->appbox->get_connection();
|
||||||
@@ -702,6 +703,7 @@ class User_Query implements User_QueryInterface
|
|||||||
public function on_base_ids(Array $base_ids = null)
|
public function on_base_ids(Array $base_ids = null)
|
||||||
{
|
{
|
||||||
if (!$base_ids)
|
if (!$base_ids)
|
||||||
|
|
||||||
return $this;
|
return $this;
|
||||||
|
|
||||||
$this->bases_restrictions = true;
|
$this->bases_restrictions = true;
|
||||||
@@ -726,6 +728,7 @@ class User_Query implements User_QueryInterface
|
|||||||
public function on_sbas_ids(Array $sbas_ids = null)
|
public function on_sbas_ids(Array $sbas_ids = null)
|
||||||
{
|
{
|
||||||
if (!$sbas_ids)
|
if (!$sbas_ids)
|
||||||
|
|
||||||
return $this;
|
return $this;
|
||||||
|
|
||||||
$this->sbas_restrictions = true;
|
$this->sbas_restrictions = true;
|
||||||
|
@@ -192,6 +192,7 @@ class connection
|
|||||||
self::$_PDO_instance[$name] = null;
|
self::$_PDO_instance[$name] = null;
|
||||||
unset(self::$_PDO_instance[$name]);
|
unset(self::$_PDO_instance[$name]);
|
||||||
}
|
}
|
||||||
|
|
||||||
return;
|
return;
|
||||||
}
|
}
|
||||||
|
|
||||||
|
@@ -829,8 +829,10 @@ class task_period_archive extends task_abstract
|
|||||||
{
|
{
|
||||||
$magicmethod = strtoupper($sxDotPhrasea->magicfile['method']);
|
$magicmethod = strtoupper($sxDotPhrasea->magicfile['method']);
|
||||||
if($magicmethod == 'LOCK' && file_exists($path . '/' . $magicfile))
|
if($magicmethod == 'LOCK' && file_exists($path . '/' . $magicfile))
|
||||||
|
|
||||||
return;
|
return;
|
||||||
elseif($magicmethod == 'UNLOCK' && !file_exists($path . '/' . $magicfile))
|
elseif($magicmethod == 'UNLOCK' && !file_exists($path . '/' . $magicfile))
|
||||||
|
|
||||||
return;
|
return;
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
Reference in New Issue
Block a user