diff options
author | icalshare <icalshare> | 2003-09-15 03:18:23 +0000 |
---|---|---|
committer | icalshare <icalshare> | 2003-09-15 03:18:23 +0000 |
commit | 916ad724a5c2c69026ab8e588feb092eeaeef93c (patch) | |
tree | b83fcea368c3d1f1eaadcda21b0494440f84f1bf /functions/init.inc.php | |
parent | fd5837eca1f02fb64c939e3c66c64c7959b219bb (diff) | |
download | phpicalendar-916ad724a5c2c69026ab8e588feb092eeaeef93c.tar.gz phpicalendar-916ad724a5c2c69026ab8e588feb092eeaeef93c.tar.bz2 phpicalendar-916ad724a5c2c69026ab8e588feb092eeaeef93c.zip |
Fixed the bug that displayed events from blacklisted cals in combined calendar view.
Diffstat (limited to 'functions/init.inc.php')
-rw-r--r-- | functions/init.inc.php | 8 |
1 files changed, 4 insertions, 4 deletions
diff --git a/functions/init.inc.php b/functions/init.inc.php index 2a145ed..669b716 100644 --- a/functions/init.inc.php +++ b/functions/init.inc.php @@ -103,12 +103,12 @@ if ($is_webcal) { // open directory $dir_handle = @opendir($calendar_path) or die(error(sprintf($error_path_lang, $calendar_path), $cal_filename)); - // build the array while (false != ($file = readdir($dir_handle))) { - if (preg_match("/^[^.].+\.ics$/", $file)) { - $file = $calendar_path.'/'.$file; - array_push($cal_filelist, $file); + if (preg_match("/^[^.].+\.ics$/", $file) && + !in_array(substr($file, 0, -4), $blacklisted_cals)) { + $file = $calendar_path.'/'.$file; + array_push($cal_filelist, $file); } } // add webcals |