for (int i = 0; i < phaseListeners.length; i++) {
PhaseListener phaseListener = phaseListeners[i];
if (isListenerForThisPhase(phaseListener, phaseId)) {
try {
phaseListener.beforePhase(new PhaseEvent(facesContext, phaseId, lifecycle));
beforePhaseSuccess[i] = true;
} catch (Exception e) {
beforePhaseSuccess[i] = false; // redundant - for clarity
LOG.error("Exception in PhaseListener " + phaseId.toString() + " beforePhase.", e);
return;