diff --git a/jstests/noPassthrough/index_shutdown_cmd_primary.js b/jstests/noPassthrough/index_shutdown_cmd_primary.js index c0c482ee490..5e4a86a4630 100644 --- a/jstests/noPassthrough/index_shutdown_cmd_primary.js +++ b/jstests/noPassthrough/index_shutdown_cmd_primary.js @@ -32,7 +32,7 @@ assert.commandWorked(coll.insert({a: 1})); IndexBuildTest.pauseIndexBuilds(primary); const createIdx = IndexBuildTest.startIndexBuild(primary, coll.getFullName(), {a: 1}); -IndexBuildTest.waitForIndexBuildToStart(testDB, coll.getName(), 'a_1'); +IndexBuildTest.waitForIndexBuildToScanCollection(testDB, coll.getName(), 'a_1'); // Stop the primary using the shutdown command without {force: true}. try {