diff options
author | Valentin Popov <info@valentineus.link> | 2017-10-26 17:28:34 +0300 |
---|---|---|
committer | Valentin Popov <info@valentineus.link> | 2017-10-26 17:28:34 +0300 |
commit | 21ad3135c8213cde62e8513dcfe4e5e299847d85 (patch) | |
tree | f79e9afde01b75cd829780bf888ab6a5bfd239ae /classes | |
parent | f87b2c82c949b828b3895c25262d91f7b45aff5c (diff) | |
download | local_webhooks-21ad3135c8213cde62e8513dcfe4e5e299847d85.tar.xz local_webhooks-21ad3135c8213cde62e8513dcfe4e5e299847d85.zip |
Bug fix
Diffstat (limited to 'classes')
-rw-r--r-- | classes/forms.php | 5 |
1 files changed, 4 insertions, 1 deletions
diff --git a/classes/forms.php b/classes/forms.php index 2e38e70..5e75050 100644 --- a/classes/forms.php +++ b/classes/forms.php @@ -52,7 +52,10 @@ class service_edit_form extends moodleform { * @param object $record */ public function set_data($record) { - $record->events = unserialize(gzuncompress(base64_decode($record->events))); + if (!empty($record->events)) { + $record->events = unserialize(gzuncompress(base64_decode($record->events))); + } + return parent::set_data($record); } |