Comment out console() calls, CS fixes

This commit is contained in:
Aleksander Machniak 2016-01-28 17:12:23 +01:00
parent f1eada2be3
commit 669feb6b02
4 changed files with 40 additions and 43 deletions

View file

@ -25,8 +25,8 @@ namespace Kolab2FA\Driver;
abstract class Base
{
public $method = null;
public $id = null;
public $method;
public $id;
public $storage;
protected $config = array();
@ -34,7 +34,6 @@ abstract class Base
protected $user_props = array();
protected $pending_changes = false;
protected $temporary = false;
protected $allowed_props = array('username');
public $user_settings = array(
@ -342,5 +341,4 @@ abstract class Base
{
return isset($this->props[$key]);
}
}

View file

@ -77,7 +77,7 @@ class HOTP extends Base
if (!strlen($secret)) {
// LOG: "no secret set for user $this->username"
console("VERIFY HOTP: no secret set for user $this->username");
// rcube::console("VERIFY HOTP: no secret set for user $this->username");
return false;
}
@ -91,11 +91,11 @@ class HOTP extends Base
}
catch (\Exception $e) {
// LOG: exception
console("VERIFY HOTP: $this->id, " . strval($e));
// rcube::console("VERIFY HOTP: $this->id, " . strval($e));
$pass = false;
}
// console('VERIFY HOTP', $this->username, $secret, $counter, $code, $pass);
// rcube::console('VERIFY HOTP', $this->username, $secret, $counter, $code, $pass);
return $pass;
}
@ -125,5 +125,4 @@ class HOTP extends Base
{
return mt_rand(1, 999);
}
}

View file

@ -71,7 +71,7 @@ class TOTP extends Base
if (!strlen($secret)) {
// LOG: "no secret set for user $this->username"
console("VERIFY TOTP: no secret set for user $this->username");
// rcube::console("VERIFY TOTP: no secret set for user $this->username");
return false;
}
@ -93,7 +93,7 @@ class TOTP extends Base
}
}
// console('VERIFY TOTP', $this->username, $secret, $code, $timestamp, $pass);
// rcube::console('VERIFY TOTP', $this->username, $secret, $code, $timestamp, $pass);
return $pass;
}
@ -102,12 +102,12 @@ class TOTP extends Base
*/
public function get_provisioning_uri()
{
console('PROV', $this->secret);
// rcube::console('PROV', $this->secret);
if (!$this->secret) {
// generate new secret and store it
$this->set('secret', $this->get('secret', true));
$this->set('created', $this->get('created', true));
console('PROV2', $this->secret);
// rcube::console('PROV2', $this->secret);
$this->commit();
}

View file

@ -84,7 +84,7 @@ class Yubikey extends Base
}
}
console('VERIFY TOTP', $this->username, $keyid, $code, $pass);
// rcube::console('VERIFY TOTP', $this->username, $keyid, $code, $pass);
return $pass;
}