cvs: smarty /libs Smarty.class.php
| From: | Messju Mohr | Date: | Mon, 28 Apr 2003 00:55:01 +0000 |
| Subject: | cvs: smarty /libs Smarty.class.php | ||
| Groups: | php.smarty.cvs | ||
| Request: | Send a blank email to php-smarty-cvs+get-570@lists.php.net to get a copy of this message | ||
messju Sun Apr 27 20:55:01 2003 EDT
Modified files:
/smarty/libs Smarty.class.php
Log:
fixed issue with object-callback when fetching a php-resource
Index: smarty/libs/Smarty.class.php
diff -u smarty/libs/Smarty.class.php:1.385 smarty/libs/Smarty.class.php:1.386
--- smarty/libs/Smarty.class.php:1.385 Sun Apr 27 20:22:41 2003
+++ smarty/libs/Smarty.class.php Sun Apr 27 20:55:01 2003
@@ -42,7 +42,7 @@
* @version 2.5.0
*/
-/* $Id: Smarty.class.php,v 1.385 2003/04/28 00:22:41 messju Exp $ */
+/* $Id: Smarty.class.php,v 1.386 2003/04/28 00:55:01 messju Exp $ */
/**
* set SMARTY_DIR to absolute path to Smarty library files.
@@ -1424,10 +1424,10 @@
}
}
} else if ($resource_type != 'file') {
- $readable = true;
$template_source = null;
- $resource_func = $this->_plugins['resource'][$resource_type][0][0];
- $readable = $resource_func($resource_name, $template_source, $this);
+ $readable =
$this->_plugin_implementation_exists($this->_plugins['resource'][$resource_type][0][0])
+ &&
call_user_func_array($this->_plugins['resource'][$resource_type][0][0],
+ array($resource_name, &$template_source, &$this));
}
/*
@@ -1456,7 +1456,6 @@
} else {
$php_resource = $template_source;
}
-
return true;
}