Buggy code:
@ RequestScoped @ Named @ Stateful @ Join ( path = "//illusion//event//{urlName}//settings" , to = "//illusion//event-settings.jsf" ) @ LoggedIn @ Secure ( Permission . ILLUSION_EVENT_MANAGE ) @ SecurityContext ( context = "@urlName" ) public class IllusionEventSettingsBackingBean extends AbstractIllusionEventBackingBean { @ Parameter private String urlName ; @ Inject private IllusionEventController illusionEventController ; @ Inject private IllusionEventNavigationController illusionEventNavigationController ; @ Override public String init ( IllusionEvent illusionEvent , IllusionEventParticipant participant ) { } public String getName ( ) { } public void setName ( String name ) { } public String getDescription ( ) { } public void setDescription ( String description ) { } public String getLocation ( ) { } public void setLocation ( String location ) { } public IllusionEventJoinMode getJoinMode ( ) { } public void setJoinMode ( IllusionEventJoinMode joinMode ) { } @ Override public String getUrlName ( ) { } public void setUrlName ( @ SecurityContext String urlName ) { } public String getStartDate ( ) { } public void setStartDate ( String startDate ) { } public String getStartTime ( ) { } public void setStartTime ( String startTime ) { } public String getEndDate ( ) { } public void setEndDate ( String endDate ) { } public String getEndTime ( ) { } public void setEndTime ( String endTime ) { } public String getDomain ( ) { } public void setDomain ( String domain ) { } public Integer getAgeLimit ( ) { } public void setAgeLimit ( Integer ageLimit ) { } public String getImageUrl ( ) { } public void setImageUrl ( String imageUrl ) { } public Boolean getBeginnerFriendly ( ) { } public void setBeginnerFriendly ( Boolean beginnerFriendly ) { } public String getSignUpStartDate ( ) { } public void setSignUpStartDate ( String signUpStartDate ) { } public String getSignUpEndDate ( ) { } public void setSignUpEndDate ( String signUpEndDate ) { } public Long getTypeId ( ) { } public void setTypeId ( Long typeId ) { } public List < Long > getGenreIds ( ) { } public void setGenreIds ( List < Long > genreIds ) { } public List < Genre > getGenres ( ) { } public List < SelectItem > getTypeSelectItems ( ) { } public String save ( ) throws Exception { IllusionEvent illusionEvent = illusionEventController . findIllusionEventByUrlName ( getUrlName ( ) ) ; illusionEventController . updateIllusionEventName ( illusionEvent , getName ( ) ) ; illusionEventController . updateIllusionEventDescription ( illusionEvent , getDescription ( ) ) ; illusionEventController . updateIllusionEventJoinMode ( illusionEvent , getJoinMode ( ) ) ; illusionEventController . updateIllusionEventStart ( illusionEvent , parseDate ( getStartISODate ( ) ) ) ; illusionEventController . updateIllusionEventEnd ( illusionEvent , parseDate ( getEndISODate ( ) ) ) ; illusionEventController . updateIllusionEventLocation ( illusionEvent , getLocation ( ) ) ; illusionEventController . updateIllusionEventType ( illusionEvent , illusionEventController . findTypeById ( getTypeId ( ) ) ) ; illusionEventController . updateIllusionEventSignUpTimes ( illusionEvent , parseDate ( getSignUpStartDate ( ) ) , parseDate ( getSignUpEndDate ( ) ) ) ; illusionEventController . updateIllusionEventAgeLimit ( illusionEvent , getAgeLimit ( ) ) ; illusionEventController . updateIllusionEventBeginnerFriendly ( illusionEvent , getBeginnerFriendly ( ) ) ; illusionEventController . updateIllusionEventImageUrl ( illusionEvent , getImageUrl ( ) ) ; <START_BUG> if ( ! ( illusionEventController . isEventAllowedDomain ( getDomain ( ) ) ) ) { <END_BUG> FacesUtils . addMessage ( SEVERITY_WARN , FacesUtils . getLocalizedValue ( "illusion.eventSettings.customDomainInvalid" ) ) ; return null ; } else { illusionEventController . updateEventDomain ( illusionEvent , getDomain ( ) ) ; } List < Genre > genres = new ArrayList < > ( ) ; for ( Long genreId : genreIds ) { Genre genre = illusionEventController . findGenreById ( genreId ) ; genres . add ( genre ) ; } illusionEventController . updateEventGenres ( illusionEvent , genres ) ; return "//illusion//event-settings.jsf?faces-redirect=true&urlName=" + ( illusionEvent . getUrlName ( ) ) ; } private String getStartISODate ( ) { } private String getEndISODate ( ) { } private String formatDate ( Date time ) { } private String formatTime ( Date time ) { } private Date parseDate ( String iso ) { } private String name ; private String description ; private String location ; private IllusionEventJoinMode joinMode ; private String startDate ; private String startTime ; private String endDate ; private String endTime ; private String domain ; private Integer ageLimit ; private String imageUrl ; private Boolean beginnerFriendly ; private String signUpStartDate ; private String signUpEndDate ; private List < Genre > genres ; private Long typeId ; private List < Long > genreIds ; private List < SelectItem > typeSelectItems ; }

Fix:
if ( ( StringUtils . isNotBlank ( getDomain ( ) ) ) && ( ! ( illusionEventController . isEventAllowedDomain ( getDomain ( ) ) ) ) ) {