Switched to using shorter ActionErrors functions
[timetracker.git] / report_send.php
index d8a0690..505613e 100644 (file)
@@ -65,7 +65,7 @@ if ($request->getMethod() == 'POST') {
   if (!ttValidString($cl_subject)) $errors->add($i18n->getKey('error.field'), $i18n->getKey('form.mail.subject'));
   if (!ttValidString($cl_comment, true)) $errors->add($i18n->getKey('error.field'), $i18n->getKey('label.comment'));
 
-  if ($errors->isEmpty()) {
+  if ($errors->no()) {
     // Save last report emails for future use.
     $sc->setValue(SYSC_LAST_REPORT_EMAIL, $cl_receiver);
     $sc->setValue(SYSC_LAST_REPORT_CC, $cl_cc);