rest-api/src/jetbrains/buildServer/server/graphql/resolver/AgentTypeResolver.java [144:158]:
- - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - -
    try {
      CloudProfile profile = myCloudManager.findProfileGloballyById(AgentTypeKey.getProfileId());
      if (profile == null) {
        return null;
      }

      CloudImage respectiveImage = null;
      CloudClientEx client = myCloudManager.getClient(profile.getProjectId(), profile.getProfileId());
      for (CloudImage image : client.getImages()) {
        SAgentType imageAgentType = myCloudManager.getDescriptionFor(profile, image.getId());
        if (imageAgentType == null) continue;

        if (AgentTypeKey.equals(imageAgentType.getAgentTypeKey())) {
          respectiveImage = image;
          break;
- - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - -



rest-api/src/jetbrains/buildServer/server/rest/data/finder/impl/CloudImageFinder.java [200:214]:
- - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - -
      try {
        CloudProfile profile = myCloudManager.findProfileGloballyById(AgentTypeKey.getProfileId());
        if (profile == null) {
          return null;
        }

        CloudImage respectiveImage = null;
        CloudClientEx client = myCloudManager.getClient(profile.getProjectId(), profile.getProfileId());
        for (CloudImage image : client.getImages()) {
          SAgentType imageAgentType = myCloudManager.getDescriptionFor(profile, image.getId());
          if (imageAgentType == null) continue;

          if (AgentTypeKey.equals(imageAgentType.getAgentTypeKey())) {
            respectiveImage = image;
            break;
- - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - -



