[Fusionforge-commits] r10152 - trunk/src/common/include

Alain Peyrat aljeux at libremir.placard.fr.eu.org
Mon Jun 28 19:29:30 CEST 2010


Author: aljeux
Date: 2010-06-28 19:29:30 +0200 (Mon, 28 Jun 2010)
New Revision: 10152

Modified:
   trunk/src/common/include/User.class.php
Log:
stripslashes removed: no longer needed.
Prefer lower username when matching.

Modified: trunk/src/common/include/User.class.php
===================================================================
--- trunk/src/common/include/User.class.php	2010-06-28 17:29:25 UTC (rev 10151)
+++ trunk/src/common/include/User.class.php	2010-06-28 17:29:30 UTC (rev 10152)
@@ -130,7 +130,7 @@
 }
 
 function &user_get_objects_by_name($username_arr) {
-	$res = db_query_params ('SELECT user_id FROM users WHERE user_name = ANY ($1)',
+	$res = db_query_params ('SELECT user_id FROM users WHERE lower(user_name) = ANY ($1)',
 				array (db_string_array_to_any_clause ($username_arr))) ;
 	$arr =& util_result_column_to_array($res,0);
 	return user_get_objects($arr);
@@ -849,7 +849,7 @@
 	 */
 	function setEmail($email) {
 
-		if (!strcasecmp($this->getEmail(), stripslashes($email))) {
+		if (!strcasecmp($this->getEmail(), $email)) {
 			return true;
 		}
 




More information about the Fusionforge-commits mailing list