WebContext ctx = WebContextFactory.get();
HttpServletRequest request = ctx.getHttpServletRequest();
User user = null;
try {
user = uAPI.loadUserById(userId, uWebAPI.getLoggedInUser(request), !uWebAPI.isLoggedToBackend(request));
} catch (NoSuchUserException e) {
Logger.error(this, e.getMessage(), e);
throw new DotDataException(e.getMessage(), e);
} catch (DotRuntimeException e) {
Logger.error(this, e.getMessage(), e);