protected final UserAccount getUserAccountFromSecurityContext() {
		final SecurityContext context = SecurityContextHolder.getContext();
		if (context != null) {
			final Authentication authentication = context.getAuthentication();
			if (authentication != null) {
				return userDAO.findFirstByProperty(UserAccount_.userId, authentication.getPrincipal().toString());
			}
		}

		return null;
	}
protected final UserAccount getUserAccountFromSecurityContext() {
		final SecurityContext context = SecurityContextHolder.getContext();
		if (context != null) {
			final Authentication authentication = context.getAuthentication();
			if (authentication != null) {
				return userDAO.findFirstByProperty(UserAccount_.userId, authentication.getPrincipal().toString());
			}
		}

		return null;
	}
protected final UserAccount getUserAccountFromSecurityContext ( ) { final SecurityContext context = SecurityContextHolder . getContext ( ) ; if ( context != null ) { final Authentication authentication = context . getAuthentication ( ) ; if ( authentication != null ) { return userDAO . findFirstByProperty ( UserAccount_ . userId , authentication . getPrincipal ( ) . toString ( ) ) ; } } return null ; }
Gets the user account from security context.

@return the user account from security context
Gets the user account from security context .