aboutsummaryrefslogtreecommitdiffstats
path: root/include/template.class.php
diff options
context:
space:
mode:
Diffstat (limited to '')
-rw-r--r--include/template.class.php13
1 files changed, 10 insertions, 3 deletions
diff --git a/include/template.class.php b/include/template.class.php
index b91d34b2a..32c224581 100644
--- a/include/template.class.php
+++ b/include/template.class.php
@@ -1366,7 +1366,7 @@ final class FileCombiner
private $is_css;
private $combinables;
- function FileCombiner($type, $combinables)
+ function FileCombiner($type, $combinables=array())
{
$this->type = $type;
$this->is_css = $type=='css';
@@ -1386,8 +1386,15 @@ final class FileCombiner
function add($combinables)
{
- foreach($combinables as $combinable)
- $this->combinables[] = $combinable;
+ if ($combinables instanceof Combinable)
+ {
+ $this->combinables[] = $combinables;
+ }
+ else
+ {
+ foreach($combinables as $combinable)
+ $this->combinables[] = $combinable;
+ }
}
function combine()