cvs: pear /Auth/Container DB.php
| From: | Martin Jansen | Date: | Thu, 01 Nov 2001 14:43:09 +0000 |
| Subject: | cvs: pear /Auth/Container DB.php | ||
| Groups: | php.pear.cvs | ||
| Request: | Send a blank email to pear-cvs+get-1230@lists.php.net to get a copy of this message | ||
mj Thu Nov 1 09:43:09 2001 EDT
Modified files:
/pear/Auth/Container DB.php
Log:
* Whitespace
Index: pear/Auth/Container/DB.php
diff -u pear/Auth/Container/DB.php:1.4 pear/Auth/Container/DB.php:1.5
--- pear/Auth/Container/DB.php:1.4 Thu Nov 1 09:42:22 2001
+++ pear/Auth/Container/DB.php Thu Nov 1 09:43:09 2001
@@ -16,7 +16,7 @@
// | Authors: Martin Jansen <mj@php.net> |
// +----------------------------------------------------------------------+
//
-// $Id: DB.php,v 1.4 2001/11/01 14:42:22 mj Exp $
+// $Id: DB.php,v 1.5 2001/11/01 14:43:09 mj Exp $
//
require_once "Auth/Container.php";
@@ -30,11 +30,11 @@
*
* @author Martin Jansen <mj@php.net>
* @package Auth
- * @version $Revision: 1.4 $
+ * @version $Revision: 1.5 $
*/
class Auth_Container_DB extends Auth_Container
{
-
+
/**
* Additional options for the storage container
* @var array
@@ -55,7 +55,7 @@
* Initate connection to the database via PEAR::DB
*
* @param $dsn string connection data or DB object
- * @return object Returns an error object if something went wrong
+ * @return object Returns an error object if something went wrong
*/
function Auth_Container_DB($dsn)
{
@@ -84,10 +84,10 @@
}
else {
- return new PEAR_Error("The given dsn was not valid in file " . __FILE__ .
" at line " . __LINE__,
- 41,
- PEAR_ERROR_RETURN,
- null,
+ return new PEAR_Error("The given dsn was not valid in file " . __FILE__ .
" at line " . __LINE__,
+ 41,
+ PEAR_ERROR_RETURN,
+ null,
null
);
}
@@ -107,7 +107,7 @@
{
$this->db = DB::Connect($dsn);
- if (DB::isError($this->db)) {
+ if (DB::isError($this->db)) {
return new DB_Error($this->db->code, PEAR_ERROR_DIE);
} else {
return true;
@@ -164,9 +164,9 @@
* @param string Password
* @return mixed Error object or boolean
*/
- function fetchData($username, $password)
- {
- $query = sprintf("SELECT %s FROM %s
+ function fetchData($username, $password)
+ {
+ $query = sprintf("SELECT %s FROM %s
WHERE %s = '%s'
AND %s = '%s'",
$this->options['usernamecol'],
@@ -178,7 +178,7 @@
);
$res = $this->db->query($query);
-
+
if (DB::isError($res)) {
return new DB_Error($res->code, PEAR_ERROR_DIE);
} else {
@@ -192,7 +192,7 @@
} else {
return false;
}
- }
+ }
}
// }}}