From cad81f2b3cb798307f917bae4441627890ce18ab Mon Sep 17 00:00:00 2001 From: Dan Marsden Date: Fri, 28 Apr 2017 13:21:34 +1200 Subject: [PATCH] fix php warning in php 5.6 --- renderer.php | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/renderer.php b/renderer.php index 6b5180c..f0549a7 100644 --- a/renderer.php +++ b/renderer.php @@ -1464,7 +1464,7 @@ class mod_attendance_renderer extends plugin_renderer_base { foreach ($prefdata->statuses as $st) { $emptyacronym = ''; $emptydescription = ''; - if (!empty(($prefdata->errors[$st->id]))) { + if (!empty($prefdata->errors) && !empty(($prefdata->errors[$st->id]))) { if (empty($prefdata->errors[$st->id]['acronym'])) { $emptyacronym = $this->construct_notice(get_string('emptyacronym', 'mod_attendance'), 'notifyproblem'); }