]> source.dussan.org Git - nextcloud-server.git/commitdiff
Get Hot New Fixes (TM)
authorJakob Sack <kde@jakobsack.de>
Sat, 16 Apr 2011 21:02:54 +0000 (23:02 +0200)
committerJakob Sack <kde@jakobsack.de>
Sat, 16 Apr 2011 21:02:54 +0000 (23:02 +0200)
docs/owncloud.sql
lib/User/database.php
lib/database.php

index 75812ad3c7e4517f2a922ccb60f204fda854942a..78fa42979b23aa8a49f44c17a144277fcc99c82b 100644 (file)
@@ -165,7 +165,6 @@ CREATE TABLE IF NOT EXISTS `properties` (
 
 CREATE TABLE IF NOT EXISTS `users` (
   `uid` varchar(64) COLLATE utf8_unicode_ci NOT NULL,
-  `name` varchar(255) COLLATE utf8_unicode_ci NOT NULL,
   `password` varchar(255) COLLATE utf8_unicode_ci NOT NULL,
   PRIMARY KEY (`uid`)
 ) ENGINE=MyISAM DEFAULT CHARSET=utf8 COLLATE=utf8_unicode_ci;
index d521cc23c42f9a61feeda89b379940f6378d2e7b..f0b68cf17d7d2af5d35b0ea77ade2a83e8c3654a 100644 (file)
@@ -71,7 +71,7 @@ class OC_USER_DATABASE extends OC_USER_BACKEND {
         * @param  string  $password  The password of the user
         */
        public static function login( $username, $password ){
-               $query = OC_DB::prepare( "SELECT `uid`, `name` FROM `*PREFIX*users` WHERE `uid` = ? AND `password` = ?" );
+               $query = OC_DB::prepare( "SELECT `uid` FROM `*PREFIX*users` WHERE `uid` = ? AND `password` = ?" );
                $result = $query->execute( array( $username, sha1( $password )));
 
                if( $result->numRows() > 0 ){
index dc4bf75649b1479ffb6c21ae18ca3b263719e43a..b620009bf50887056e408c0045eec616be469778 100644 (file)
@@ -152,7 +152,7 @@ class OC_DB {
                // Die if we have an error (error means: bad query, not 0 results!)
                if( PEAR::isError($result)) {
                        $entry = 'DB Error: "'.$result->getMessage().'"<br />';
-                       $entry .= 'Offending command was: '.$cmd.'<br />';
+                       $entry .= 'Offending command was: '.$query.'<br />';
                        error_log( $entry );
                        die( $entry );
                }