Fixed issue when there are no teachers

This commit is contained in:
Mark Nelson 2015-12-14 11:10:50 +08:00
parent 2416e8a3e0
commit 344710b51d

View file

@ -48,8 +48,10 @@ class element extends \mod_customcert\element {
* @return string the text * @return string the text
*/ */
public function save_unique_data($data) { public function save_unique_data($data) {
if (!empty($data->teacher)) {
return $data->teacher; return $data->teacher;
} }
}
/** /**
* Handles rendering the element on the pdf. * Handles rendering the element on the pdf.