aboutsummaryrefslogtreecommitdiffstats
path: root/include/comanche.php
diff options
context:
space:
mode:
authorroyalterra <royalterra@users.noreply.github.com>2015-12-11 09:39:01 +0000
committerroyalterra <royalterra@users.noreply.github.com>2015-12-11 09:39:01 +0000
commit4ff31d0a4140d923cbb8ddbe18ccf578a367375f (patch)
tree1f63d4b042c3dbf7bfe2c3e74f0a24ef2e5f94ec /include/comanche.php
parentb92cc852d142940f0f8dd78ddf7be835dc8b9e07 (diff)
parentf73c82632f213ac7971b54220b4a0c87d354ca1e (diff)
downloadvolse-hubzilla-4ff31d0a4140d923cbb8ddbe18ccf578a367375f.tar.gz
volse-hubzilla-4ff31d0a4140d923cbb8ddbe18ccf578a367375f.tar.bz2
volse-hubzilla-4ff31d0a4140d923cbb8ddbe18ccf578a367375f.zip
Merge pull request #1 from redmatrix/master
merge branches
Diffstat (limited to 'include/comanche.php')
-rw-r--r--include/comanche.php9
1 files changed, 5 insertions, 4 deletions
diff --git a/include/comanche.php b/include/comanche.php
index 9585a6578..ef71886f2 100644
--- a/include/comanche.php
+++ b/include/comanche.php
@@ -282,15 +282,16 @@ function comanche_widget($name, $text) {
}
}
- if(file_exists('widget/' . trim($name) . '.php'))
+ $func = 'widget_' . trim($name);
+
+ if((! function_exists($func)) && file_exists('widget/' . trim($name) . '.php'))
require_once('widget/' . trim($name) . '.php');
else {
- $theme_widget = 'widget_' . trim($name) . '.php';
- if(theme_include($theme_widget))
+ $theme_widget = $func . '.php';
+ if((! function_exists($func)) && theme_include($theme_widget))
require_once(theme_include($theme_widget));
}
- $func = 'widget_' . trim($name);
if (function_exists($func))
return $func($vars);
}