appdb/include objectManager.php
WineHQ
wineowner at wine.codeweavers.com
Mon Jun 18 19:29:37 CDT 2007
ChangeSet ID: 31224
CVSROOT: /opt/cvs-commit
Module name: appdb
Changes by: wineowner at winehq.org 2007/06/18 19:29:37
Modified files:
include : objectManager.php
Log message:
Alexander Nicolaysen Sørnes <alex at thehandofagony.com>
Don't display editor for non-existent entries
Patch: http://cvs.winehq.org/patch.py?id=31224
Old revision New revision Changes Path
1.31 1.32 +8 -0 appdb/include/objectManager.php
Index: appdb/include/objectManager.php
diff -u -p appdb/include/objectManager.php:1.31 appdb/include/objectManager.php:1.32
--- appdb/include/objectManager.php:1.31 19 Jun 2007 0:29:37 -0000
+++ appdb/include/objectManager.php 19 Jun 2007 0:29:37 -0000
@@ -181,6 +181,14 @@ class ObjectManager
$oObject = new $this->sClass($this->iId);
+ /* The entry does not exist */
+ if(!$oObject->objectGetId())
+ {
+ echo "<font color=\"red\">There is no entry with that id in the database</font>.\n";
+ echo "</div>";
+ return;
+ }
+
/* Display errors, if any, and fetch form data */
if($this->displayErrors($sErrors))
{
More information about the wine-cvs
mailing list