summaryrefslogtreecommitdiff
path: root/program/include/main.inc
diff options
context:
space:
mode:
Diffstat (limited to 'program/include/main.inc')
-rw-r--r--program/include/main.inc4
1 files changed, 3 insertions, 1 deletions
diff --git a/program/include/main.inc b/program/include/main.inc
index 0e206166e..ce9eaf069 100644
--- a/program/include/main.inc
+++ b/program/include/main.inc
@@ -947,8 +947,10 @@ function format_date($date, $format=NULL)
if (is_numeric($date))
$ts = $date;
- else
+ else if (!empty($date))
$ts = strtotime($date);
+ else
+ return '';
// convert time to user's timezone
$timestamp = $ts - date('Z', $ts) + ($CONFIG['timezone'] * 3600);