cvs: pear /MDB2_Schema/MDB2/Schema Parser.php

From: Date: Sun, 26 Mar 2006 09:51:38 +0000
Subject: cvs: pear /MDB2_Schema/MDB2/Schema Parser.php
Groups: php.pear.cvs 
Request: Send a blank email to pear-cvs+get-39324@lists.php.net to get a copy of this message
lsmith Sun Mar 26 09:51:38 2006 UTC Modified files: /pear/MDB2_Schema/MDB2/Schema Parser.php Log: - if no valid_types are set skip type check http://cvs.php.net/viewcvs.cgi/pear/MDB2_Schema/MDB2/Schema/Parser.php?r1=1.29&r2=1.30&diff_format=u Index: pear/MDB2_Schema/MDB2/Schema/Parser.php diff -u pear/MDB2_Schema/MDB2/Schema/Parser.php:1.29 pear/MDB2_Schema/MDB2/Schema/Parser.php:1.30 --- pear/MDB2_Schema/MDB2/Schema/Parser.php:1.29 Tue Mar 21 09:38:12 2006 +++ pear/MDB2_Schema/MDB2/Schema/Parser.php Sun Mar 26 09:51:38 2006 @@ -42,7 +42,7 @@ // | Author: Christian Dickmann <dickmann@php.net> | // +----------------------------------------------------------------------+ // -// $Id: Parser.php,v 1.29 2006/03/21 09:38:12 lsmith Exp $ +// $Id: Parser.php,v 1.30 2006/03/26 09:51:38 lsmith Exp $ // require_once 'XML/Parser.php'; @@ -281,7 +281,10 @@ } } /* Type check */ - if (!array_key_exists('type', $this->field) || !array_key_exists($this->field['type'], $this->valid_types)) { + if (!array_key_exists('type', $this->field)) { + $this->raiseError('no field type specified', null, $xp); + } + if (!empty($this->valid_types) && !array_key_exists($this->field['type'], $this->valid_types)) { $this->raiseError('no valid field type ("'.$this->field['type'].'") specified', null, $xp); } switch ($this->field['type']) {

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