//Otherwise, just throw the NotFoundException to bounce the email.
if( configurationManager.isDefaultUserEnabled() ) {
EmailAddress defaultAddress = configurationManager.getDefaultUser();
//If this throws a NotFoundException, go ahead and let it bounce.
user = configurationManager.getUser( defaultAddress );
if( user == null ) throw new NotFoundException();
if( log.isDebugEnabled() ) { log.info( "Delivering message addressed to: " + address + " to default user: " + defaultAddress ); }
}
else {
throw new NotFoundException( "User does not exist and no default delivery options found." );
}
}
//The file to write to.
File messageFile = null;