return ResponseFactory.response(OK, UserResponse.createFromUser(fetchedUser), JsonPolicyDef.Policy.USER_PUBLISHED);
}
@Override
public Response getCurrent() {
HivePrincipal principal = (HivePrincipal) SecurityContextHolder.getContext().getAuthentication().getPrincipal();
<BUG>Long id = principal.getUser() != null ? principal.getUser().getId() : principal.getKey().getUser().getId();
UserVO currentUser = userService.findUserWithNetworks(id);</BUG>
if (currentUser == null) {
return ResponseFactory.response(CONFLICT, new ErrorResponse(CONFLICT.getStatusCode(), Messages.CAN_NOT_GET_CURRENT_USER));
}

return ResponseFactory.response(OK, UserResponse.createFromUser(fetchedUser), JsonPolicyDef.Policy.USER_PUBLISHED);
}
@Override
public Response getCurrent() {
HivePrincipal principal = (HivePrincipal) SecurityContextHolder.getContext().getAuthentication().getPrincipal();
Long id = principal.getUser().getId();
UserVO currentUser = userService.findUserWithNetworks(id);
if (currentUser == null) {
return ResponseFactory.response(CONFLICT, new ErrorResponse(CONFLICT.getStatusCode(), Messages.CAN_NOT_GET_CURRENT_USER));
}
