From ed5ca9e4ccb2741c33ac2c88082728066bc715fb Mon Sep 17 00:00:00 2001 From: redmatrix Date: Fri, 18 Dec 2015 14:55:19 -0800 Subject: use realpath to bypass symlinks and check actually directory --- include/comanche.php | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) (limited to 'include/comanche.php') diff --git a/include/comanche.php b/include/comanche.php index 5bffc3dbf..1537226ca 100644 --- a/include/comanche.php +++ b/include/comanche.php @@ -287,7 +287,7 @@ function comanche_widget($name, $text) { if(! function_exists($func)) { if(file_exists('widget/' . trim($name) . '.php')) require_once('widget/' . trim($name) . '.php'); - elseif(is_dir('widget/'. trim($name)) + elseif(folder_exists('widget/'. trim($name)) && (file_exists('widget/' . trim($name) . '/' . trim($name) . '.php'))) require_once('widget/' . trim($name) . '/' . trim($name) . '.php'); } -- cgit v1.2.3