Fix preloading of change page
We forgot to add the PARENTS list change option to IndexPreloadingUtil
with change I271d8cdc. Adding in this change.
Release-Notes: skip
Change-Id: I2fafb053acbbd926ca03750c717d45cdfcab1882
diff --git a/java/com/google/gerrit/httpd/raw/IndexPreloadingUtil.java b/java/com/google/gerrit/httpd/raw/IndexPreloadingUtil.java
index 2ab8ceb..4c42e79 100644
--- a/java/com/google/gerrit/httpd/raw/IndexPreloadingUtil.java
+++ b/java/com/google/gerrit/httpd/raw/IndexPreloadingUtil.java
@@ -102,7 +102,8 @@
ListChangesOption.SUBMITTABLE,
ListChangesOption.WEB_LINKS,
ListChangesOption.SKIP_DIFFSTAT,
- ListChangesOption.SUBMIT_REQUIREMENTS);
+ ListChangesOption.SUBMIT_REQUIREMENTS,
+ ListChangesOption.PARENTS);
@Nullable
public static String getPath(@Nullable String requestedURL) throws URISyntaxException {
diff --git a/javatests/com/google/gerrit/httpd/raw/IndexHtmlUtilTest.java b/javatests/com/google/gerrit/httpd/raw/IndexHtmlUtilTest.java
index 2236f3d..c06d231 100644
--- a/javatests/com/google/gerrit/httpd/raw/IndexHtmlUtilTest.java
+++ b/javatests/com/google/gerrit/httpd/raw/IndexHtmlUtilTest.java
@@ -116,7 +116,7 @@
assertThat(dynamicTemplateData(gerritApi, "/c/project/+/123"))
.containsAtLeast(
- "defaultChangeDetailHex", "1916394",
+ "defaultChangeDetailHex", "9916394",
"changeRequestsPath", "changes/project~123");
}
diff --git a/polygerrit-ui/app/services/gr-rest-api/gr-rest-api-impl.ts b/polygerrit-ui/app/services/gr-rest-api/gr-rest-api-impl.ts
index ae19f11..1deec72 100644
--- a/polygerrit-ui/app/services/gr-rest-api/gr-rest-api-impl.ts
+++ b/polygerrit-ui/app/services/gr-rest-api/gr-rest-api-impl.ts
@@ -1264,7 +1264,7 @@
const config = await this.getConfig(false);
// This list MUST be kept in sync with
- // ChangeIT#changeDetailsDoesNotRequireIndex
+ // ChangeIT#changeDetailsDoesNotRequireIndex and IndexPreloadingUtil#CHANGE_DETAIL_OPTIONS
// This list MUST be kept in sync with getResponseFormatOptions
const options = [
ListChangesOption.ALL_COMMITS,
@@ -1292,7 +1292,7 @@
const config = await this.getConfig(false);
// This list MUST be kept in sync with
- // ChangeIT#changeDetailsDoesNotRequireIndex
+ // ChangeIT#changeDetailsDoesNotRequireIndex and IndexPreloadingUtil#CHANGE_DETAIL_OPTIONS
// This list MUST be kept in sync with getChangeOptions
const options = [
'ALL_COMMITS',