Core (@NotNull Ini ini) { String hooksPath = null; List<Profile.Section> sections = ContainerUtil.notNullize(ini.getAll(CORE_SECTION)); for (Profile.Section section : ContainerUtil.reverse(sections)) { // take entry from last section for duplicates if (hooksPath == null) hooksPath = ContainerUtil.getLastItem(section.getAll("hookspath")); } return new Core(hooksPath); }