summaryrefslogtreecommitdiffstats
path: root/lib/user
diff options
context:
space:
mode:
authorBart Visscher <bartv@thisnet.nl>2012-06-08 21:23:25 +0200
committerBart Visscher <bartv@thisnet.nl>2012-06-19 23:16:17 +0200
commitcff1b6e69901c84aadbb7d9f9677756f4c813837 (patch)
tree12ea6c806626927955c13678fd0d1d98f5a13c00 /lib/user
parentbb649dd0d5accbdf1d993cdfbf0e10fd2e4f9f0b (diff)
downloadnextcloud-server-cff1b6e69901c84aadbb7d9f9677756f4c813837.tar.gz
nextcloud-server-cff1b6e69901c84aadbb7d9f9677756f4c813837.zip
Don't use substr to get first char of string
Diffstat (limited to 'lib/user')
-rw-r--r--lib/user/database.php2
1 files changed, 1 insertions, 1 deletions
diff --git a/lib/user/database.php b/lib/user/database.php
index a9b01957d42..a69fe49a0b9 100644
--- a/lib/user/database.php
+++ b/lib/user/database.php
@@ -129,7 +129,7 @@ class OC_User_Database extends OC_User_Backend {
$row=$result->fetchRow();
if($row){
$storedHash=$row['password'];
- if (substr($storedHash,0,1)=='$'){//the new phpass based hashing
+ if ($storedHash[0]=='$'){//the new phpass based hashing
$hasher=$this->getHasher();
if($hasher->CheckPassword($password.OC_Config::getValue('passwordsalt', ''), $storedHash)){
return $row['uid'];