cvs: smarty /libs/plugins core.parse_file_path.php
| From: | Monte Ohrt | Date: | Tue, 10 Jun 2003 14:01:23 +0000 |
| Subject: | cvs: smarty /libs/plugins core.parse_file_path.php | ||
| Groups: | php.smarty.cvs | ||
| Request: | Send a blank email to php-smarty-cvs+get-637@lists.php.net to get a copy of this message | ||
mohrt Tue Jun 10 10:01:23 2003 EDT
Modified files:
/smarty/libs/plugins core.parse_file_path.php
Log:
fix bug with resource_type resolving
Index: smarty/libs/plugins/core.parse_file_path.php
diff -u smarty/libs/plugins/core.parse_file_path.php:1.3
smarty/libs/plugins/core.parse_file_path.php:1.4
--- smarty/libs/plugins/core.parse_file_path.php:1.3 Fri Jun 6 16:30:53 2003
+++ smarty/libs/plugins/core.parse_file_path.php Tue Jun 10 10:01:22 2003
@@ -24,14 +24,14 @@
$_file_path_parts = explode(':', $params['file_path'], 2);
if (count($_file_path_parts) == 1) {
- // no resource type, treat as type "file"
+ // no resource type given
$params['resource_type'] = $this->default_resource_type;
$params['resource_name'] = $_file_path_parts[0];
} else {
if(strlen($_file_path_parts[0]) == 1) {
// 1 char is not resource type, but part of filepath
- $params['resource_type'] = 'file';
- $params['resource_name'] = $params['file_path'];
+ $params['resource_type'] = $this->default_resource_type;
+ $params['resource_name'] = $params['file_path'];
} else {
$params['resource_type'] = $_file_path_parts[0];
$params['resource_name'] = $_file_path_parts[1];