cvs: pear /MDB/MDB/Modules/Manager Common.php

From: Date: Sat, 01 Feb 2003 17:35:45 +0000
Subject: cvs: pear /MDB/MDB/Modules/Manager Common.php
Groups: php.pear.cvs 
Request: Send a blank email to pear-cvs+get-8638@lists.php.net to get a copy of this message
lsmith Sat Feb 1 12:35:45 2003 EDT Modified files: /pear/MDB/MDB/Modules/Manager Common.php Log: incorrect error handling typo fixes Index: pear/MDB/MDB/Modules/Manager/Common.php diff -u pear/MDB/MDB/Modules/Manager/Common.php:1.31 pear/MDB/MDB/Modules/Manager/Common.php:1.32 --- pear/MDB/MDB/Modules/Manager/Common.php:1.31 Sun Jan 19 06:13:36 2003 +++ pear/MDB/MDB/Modules/Manager/Common.php Sat Feb 1 12:35:45 2003 @@ -42,7 +42,7 @@ // | Author: Lukas Smith <smith@backendmedia.com> | // +----------------------------------------------------------------------+ // -// $Id: Common.php,v 1.31 2003/01/19 11:13:36 lsmith Exp $ +// $Id: Common.php,v 1.32 2003/02/01 17:35:45 lsmith Exp $ // if(!defined('MDB_MANAGER_COMMON_INCLUDED')) @@ -266,9 +266,8 @@ if (count($fields) == 0) { return($db->raiseError(MDB_ERROR_CANNOT_CREATE, '', '', 'no fields specified for table "'.$name.'"')); } - $query_fields = ''; - if (!$db->getFieldDeclarationList($fields, $query_fields)) { - return($db->raiseError(MDB_ERROR_CANNOT_CREATE, '', '', 'unkown error')); + if (MDB::isError($query_fields = $db->getFieldDeclarationList($fields))) { + return($query_fields); } return($db->query("CREATE TABLE $name ($query_fields)")); } @@ -406,7 +405,7 @@ function listDatabases(&$db) { return($db->raiseError(MDB_ERROR_NOT_CAPABLE, '', '', - 'List Databses: list databases is not supported')); + 'List Databases: list databases is not supported')); } // }}} @@ -623,7 +622,7 @@ function getTableIndexDefinition(&$db, $table, $index) { return($db->raiseError(MDB_ERROR_NOT_CAPABLE, '', '', - 'get table index definition: getting index definition is not supported')); + 'Get table index definition: getting index definition is not supported')); } // }}}

« previous php.pear.cvs (#8638) next »