aboutsummaryrefslogtreecommitdiffstats
path: root/include
diff options
context:
space:
mode:
Diffstat (limited to 'include')
-rw-r--r--include/template_processor.php8
1 files changed, 5 insertions, 3 deletions
diff --git a/include/template_processor.php b/include/template_processor.php
index 459ffb2d1..dc5c24de3 100644
--- a/include/template_processor.php
+++ b/include/template_processor.php
@@ -164,9 +164,11 @@
$a = get_app();
$this->lang=array();
- foreach ($a->strings as $k=>$v){
- $k = preg_replace("/[^a-z0-9-]/", "", str_replace(" ","-", strtolower($k)));
- $this->lang[$k] = $v;
+ if(is_array($a->strings) && count($a->strings)) {
+ foreach ($a->strings as $k=>$v){
+ $k = preg_replace("/[^a-z0-9-]/", "", str_replace(" ","-", strtolower($k)));
+ $this->lang[$k] = $v;
+ }
}
return $this->lang;
}