Changeset 479 for trunk/lib/Auth_SQL.inc.php
- Timestamp:
- May 3, 2014 11:09:03 PM (10 years ago)
- File:
-
- 1 edited
Legend:
- Unmodified
- Added
- Removed
-
trunk/lib/Auth_SQL.inc.php
r478 r479 129 129 public function __construct($namespace='') 130 130 { 131 131 $app =& App::getInstance(); 132 132 133 133 $this->_ns = $namespace; … … 155 155 public function initDB($recreate_db=false) 156 156 { 157 158 157 $app =& App::getInstance(); 158 $db =& DB::getInstance(); 159 159 160 160 … … 276 276 public function getParam($param) 277 277 { 278 278 $app =& App::getInstance(); 279 279 280 280 if (array_key_exists($param, $this->_params)) { … … 293 293 public function clear() 294 294 { 295 295 $db =& DB::getInstance(); 296 296 297 297 $this->initDB(); … … 363 363 public function authenticate($username, $password) 364 364 { 365 366 365 $app =& App::getInstance(); 366 $db =& DB::getInstance(); 367 367 368 368 $this->initDB(); … … 414 414 public function login($username, $password) 415 415 { 416 417 416 $app =& App::getInstance(); 417 $db =& DB::getInstance(); 418 418 419 419 $this->initDB(); … … 541 541 public function isLoggedIn($user_id=null) 542 542 { 543 544 543 $app =& App::getInstance(); 544 $db =& DB::getInstance(); 545 545 546 546 $this->initDB(); … … 673 673 public function requireLogin($message='', $type=MSG_NOTICE, $file=null, $line=null) 674 674 { 675 675 $app =& App::getInstance(); 676 676 677 677 if (!$this->isLoggedIn()) { … … 695 695 public function blockAccount($user_id=null, $reason='') 696 696 { 697 698 697 $app =& App::getInstance(); 698 $db =& DB::getInstance(); 699 699 700 700 $this->initDB(); … … 725 725 public function isBlocked($user_id=null) 726 726 { 727 727 $db =& DB::getInstance(); 728 728 729 729 $this->initDB(); … … 747 747 public function unblockAccount($user_id=null) 748 748 { 749 749 $db =& DB::getInstance(); 750 750 751 751 $this->initDB(); … … 771 771 public function usernameExists($username) 772 772 { 773 773 $db =& DB::getInstance(); 774 774 775 775 $this->initDB(); … … 791 791 public function getUsername($user_id) 792 792 { 793 793 $db =& DB::getInstance(); 794 794 795 795 $this->initDB(); … … 903 903 public function setPassword($user_id=null, $password) 904 904 { 905 906 905 $app =& App::getInstance(); 906 $db =& DB::getInstance(); 907 907 908 908 $this->initDB(); … … 953 953 public function resetPassword($user_id=null, $reason='') 954 954 { 955 956 955 $app =& App::getInstance(); 956 $db =& DB::getInstance(); 957 957 958 958 $this->initDB(); … … 1040 1040 public function requireAccessClearance($security_zone, $message='') 1041 1041 { 1042 1042 $app =& App::getInstance(); 1043 1043 1044 1044 $zone_members = preg_split('/,\s*/', $security_zone);
Note: See TracChangeset
for help on using the changeset viewer.