/** * INTERNAL METHOD<br> * Get the email address from system settings or the evaluation * * @param eval * @return an email address * @throws IllegalStateException if a from address cannot be found */ public String getFromEmailOrFail(EvalEvaluation eval) { String from = (String) settings.get(EvalSettings.FROM_EMAIL_ADDRESS); if (eval.getReminderFromEmail() != null && !"".equals(eval.getReminderFromEmail())) { from = eval.getReminderFromEmail(); } if (from == null) { throw new IllegalStateException( "Could not get a from email address from system settings or the evaluation"); } return from; }