diff options
author | Stig Bakken <ssb@php.net> | 2000-02-25 21:18:01 +0000 |
---|---|---|
committer | Stig Bakken <ssb@php.net> | 2000-02-25 21:18:01 +0000 |
commit | 117087697414b89077b2485ed3796f62f75750f9 (patch) | |
tree | 90897fe745f5530404a2a9de9b081eea91909ab4 /pear | |
parent | 33a564c971ef908ef9879bee32798c54bdabc079 (diff) | |
download | php-git-117087697414b89077b2485ed3796f62f75750f9.tar.gz |
add a note about include return values
Diffstat (limited to 'pear')
-rw-r--r-- | pear/DB.php | 11 |
1 files changed, 10 insertions, 1 deletions
diff --git a/pear/DB.php b/pear/DB.php index 3439b351cc..6781c58242 100644 --- a/pear/DB.php +++ b/pear/DB.php @@ -203,11 +203,20 @@ class DB { // "include" should be replaced with "import" once PHP gets it $pkgname = 'DB/' . $type; if (!is_array($USED_PACKAGES) || !$USED_PACKAGES[$pkgname]) { - if (!@include("${pkgname}.php")) { + $file = "${pkgname}.php"; + include($file); +/* + + This suddenly stopped working. I thought include() was supposed to + return a boolean? [ssb 20000218] + + if (!include($file)) { + print "'$file' not found<br>\n"; return DB_ERROR_NOT_FOUND; } else { $USED_PACKAGES[$pkgname] = true; } +*/ } $classname = 'DB_' . $type; $obj = new $classname; |