private static void resolveBundleOrder(@NotNull ClassLoader loader,
                                         @NotNull Path pathToBundle,
                                         @NotNull List<? extends Path> orderedPaths,
                                         @NotNull Map<? super LocalizationOrder, ? super ResourceBundle> bundleOrderMap,
                                         @NotNull BiFunction<? super @NotNull ClassLoader, ? super Locale, ? extends @NotNull ResourceBundle> bundleResolver,
                                         @NotNull Locale locale) {
    ResourceBundle bundle = bundleResolver.apply(loader, locale);
    try {
      while (bundle != null) {
        putBundleOrder(bundle, bundleOrderMap, orderedPaths);
        bundle = getParent(bundle);
      }
    }
    catch (Throwable throwable) {
      LOG.info(throwable);
    }
    for (ResourceBundle localizedBundle : getBundlesFromLocalizationFolder(pathToBundle, loader, locale)) {
      putBundleOrder(localizedBundle, bundleOrderMap, orderedPaths);
    }
  }
private static void resolveBundleOrder(@NotNull ClassLoader loader,
                                         @NotNull Path pathToBundle,
                                         @NotNull List<? extends Path> orderedPaths,
                                         @NotNull Map<? super LocalizationOrder, ? super ResourceBundle> bundleOrderMap,
                                         @NotNull BiFunction<? super @NotNull ClassLoader, ? super Locale, ? extends @NotNull ResourceBundle> bundleResolver,
                                         @NotNull Locale locale)