From 5211fb037de625f589624e589e4de3cccff9b254 Mon Sep 17 00:00:00 2001 From: wangyidong Date: Thu, 13 Jun 2013 07:35:51 +0000 Subject: [PATCH] * fix a bug for ls in nginx. --- framework/helper.class.php | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/framework/helper.class.php b/framework/helper.class.php index 3ad3cd4499..4117b34618 100644 --- a/framework/helper.class.php +++ b/framework/helper.class.php @@ -400,7 +400,7 @@ class helper $files = array(); $dir = realpath($dir); if(is_dir($dir)) $files = glob($dir . DIRECTORY_SEPARATOR . '*' . $pattern); - return $files; + return empty($files) ? array() : $files; } /**