cvs: pear /DB/DB storage.php

From: Date: Mon, 29 Sep 2003 12:10:18 +0000
Subject: cvs: pear /DB/DB storage.php
Groups: php.pear.cvs 
Request: Send a blank email to pear-cvs+get-13166@lists.php.net to get a copy of this message
mj Mon Sep 29 08:10:18 2003 EDT Modified files: /pear/DB/DB storage.php Log: * Some cleanup: - Using <br /> instead of <br> - Removing usage of @ and replacing that with a more elaborate construct. - Removing usage of non-existing member variable $_discard. Index: pear/DB/DB/storage.php diff -u pear/DB/DB/storage.php:1.6 pear/DB/DB/storage.php:1.7 --- pear/DB/DB/storage.php:1.6 Wed May 7 12:58:28 2003 +++ pear/DB/DB/storage.php Mon Sep 29 08:10:18 2003 @@ -16,7 +16,7 @@ // | Author: Stig Bakken <stig@php.net> | // +----------------------------------------------------------------------+ // -// $Id: storage.php,v 1.6 2003/05/07 16:58:28 mj Exp $ +// $Id: storage.php,v 1.7 2003/09/29 12:10:18 mj Exp $ // // DB_storage: a class that lets you return SQL data as objects that // can be manipulated and that updates the database accordingly. @@ -271,7 +271,7 @@ while (list($prop, $foo) = each($this->_properties)) { print "$prop = "; print htmlentities($this->$prop); - print "<BR>\n"; + print "<br />\n"; } } @@ -375,7 +375,11 @@ } if ($valid) { $this->$property = $newvalue; - @$this->_changes[$property]++; + if (empty($this->_changes[$property])) { + $this->_changes[$property] = 0; + } else { + $this->_changes[$property]++; + } } else { return $this->raiseError(null, DB_ERROR_INVALID, null, null, "invalid field: $property", @@ -417,7 +421,7 @@ */ function _DB_storage() { - if (empty($this->_discard) && sizeof($this->_changes)) { + if (sizeof($this->_changes)) { $this->store(); } $this->_properties = array();

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