if (componentMessageLists != null && !(componentMessageLists.isEmpty())) {
for (Iterator<FacesMessage> i =
new ComponentMessagesIterator(componentMessageLists);
i.hasNext();) {
Severity severity = i.next().getSeverity();
if (result == null || severity.compareTo(result) > 0) {
result = severity;
}
if (result == FacesMessage.SEVERITY_FATAL) {
break;
}