From 12f16414b7f05f7bd8fe51528ac5ef5adabc1caf Mon Sep 17 00:00:00 2001 From: Florian Larysch Date: Fri, 6 Oct 2017 13:33:36 +0200 Subject: downloader: handle conferences without end date Some conferences might not have an end date, but might be disabled in their config nonetheless. This leads to a situation which causes a null dereference in the downloader code. Fix this by not downloading data for conferences in such a state, as it stands to reason that we don't care about them anymore if we explicitly disabled them. --- command/download.php | 3 +++ 1 file changed, 3 insertions(+) (limited to 'command') diff --git a/command/download.php b/command/download.php index 2cf997e..d761ff3 100644 --- a/command/download.php +++ b/command/download.php @@ -36,6 +36,9 @@ if(isset($conf['MAX_CONFERENCE_AGE'])) return true; } + if($conference->endsAt() == null) + return false; + $isBefore = $conference->endsAt() < $conferencesAfter; if($isBefore) { -- cgit v1.2.3