From 691acc8ae61e278e991e46e3ada02e1b6df8171a Mon Sep 17 00:00:00 2001 From: Leandro Lucarella Date: Wed, 4 Feb 2004 21:38:51 +0000 Subject: [PATCH] Bugfixes. --- lib/MECON/Usuario.php | 12 +++++------- 1 file changed, 5 insertions(+), 7 deletions(-) diff --git a/lib/MECON/Usuario.php b/lib/MECON/Usuario.php index 3308cf7..0558d8a 100644 --- a/lib/MECON/Usuario.php +++ b/lib/MECON/Usuario.php @@ -89,7 +89,7 @@ class MECON_Usuario { if (DB::isError($result)) { trigger_error($result->getMessage(), E_USER_ERROR); } elseif ($result->NumRows()>0) { - $row = $result->fetchRow(); + $row = $result->fetchRow(DB_FETCHMODE_ORDERED); $login = $row[0]; $nombre = $row[1]; $this->login=$login; @@ -119,12 +119,10 @@ class MECON_Usuario { if (DB::isError($result)) { trigger_error($result->getMessage(), E_USER_ERROR); } elseif ($result->NumRows()>0) { - $row = $result->fetchRow(); - $dni = $row[0]; - $nombre = $row[1]; - $this->dni=$dni; - $this->nombre=$nombre; - $this->login=$login; + $row = $result->fetchRow(DB_FETCHMODE_ORDERED); + $this->dni = $row[0]; + $this->nombre = $row[1]; + $this->login = $login; } else { trigger_error('El usuario '.$login.' no existe, debe loguearse al menos una vez a la intranet.'); -- 2.43.0