mirror of
https://github.com/alchemy-fr/Phraseanet.git
synced 2025-10-14 21:43:18 +00:00
Cleanup namepaces, variables uses
This commit is contained in:
@@ -249,7 +249,6 @@ class Session_Authentication_Native implements Session_Authentication_Interface
|
||||
protected function check_and_revoke_badlogs($ip)
|
||||
{
|
||||
$conn = $this->app['phraseanet.appbox']->get_connection();
|
||||
$registry = $this->app['phraseanet.registry'];
|
||||
|
||||
$sql = 'SELECT id FROM badlog
|
||||
WHERE (login = :login OR ip = :ip) AND locked="1"';
|
||||
@@ -271,7 +270,7 @@ class Session_Authentication_Native implements Session_Authentication_Interface
|
||||
$stmt->execute(array(':login' => $this->login, ':ip' => $ip));
|
||||
$stmt->closeCursor();
|
||||
} elseif ($row_count > 9) {
|
||||
if ($this->is_captcha_activated($registry))
|
||||
if ($this->is_captcha_activated($this->app['phraseanet.registry']))
|
||||
throw new Exception_Session_RequireCaptcha('Require captcha');
|
||||
}
|
||||
|
||||
@@ -285,8 +284,6 @@ class Session_Authentication_Native implements Session_Authentication_Interface
|
||||
*/
|
||||
protected function is_captcha_activated(registryInterface $registry)
|
||||
{
|
||||
$registry = $this->app['phraseanet.registry'];
|
||||
|
||||
return ($registry->get('GV_captchas')
|
||||
&& trim($registry->get('GV_captcha_private_key')) !== ''
|
||||
&& trim($registry->get('GV_captcha_public_key') !== ''));
|
||||
|
@@ -37,12 +37,6 @@ class Session_Authentication_PersistentCookie implements Session_Authentication_
|
||||
*/
|
||||
protected $ses_id;
|
||||
|
||||
/**
|
||||
*
|
||||
* @param Application $appbox
|
||||
* @param type $persistent_cookie
|
||||
* @return Session_Authentication_PersistentCookie
|
||||
*/
|
||||
public function __construct(Application $app, $persistent_cookie)
|
||||
{
|
||||
$this->app= $app;
|
||||
|
@@ -32,12 +32,6 @@ class Session_Authentication_Token implements Session_Authentication_Interface
|
||||
protected $token;
|
||||
protected $user;
|
||||
|
||||
/**
|
||||
*
|
||||
* @param appbox $appbox
|
||||
* @param type $token
|
||||
* @return Session_Authentication_Token
|
||||
*/
|
||||
public function __construct(Application $app, $token)
|
||||
{
|
||||
$this->app = $app;
|
||||
|
@@ -100,7 +100,6 @@ class Session_Logger
|
||||
public static function create(Application $app, databox $databox, Browser $browser)
|
||||
{
|
||||
$colls = array();
|
||||
$registry = $app['phraseanet.registry'];
|
||||
|
||||
if ($app['phraseanet.user']) {
|
||||
$bases = $app['phraseanet.user']->ACL()->get_granted_base(array(), array($databox->get_sbas_id()));
|
||||
|
Reference in New Issue
Block a user