code: public static Profile findProfile(Model mavenModel, String profileId) {
          List<Profile> profiles = mavenModel.getProfiles();
          if (profiles != null) {
              for (Profile profile : profiles) {
                  if (Objects.equal(profile.getId(), profileId)) {
                      return profile;
                  }
              }
          }
          return null;
      }
docs: Returns the profile for the given id or null if it could not be found