Skip to content

Commit 7a8a4c3

Browse files
committed
fix(MongoBinaryDownloadUrl): getDownloadUrl: try "DOWNLOAD_URL" before getArchiveName
1 parent ba80e61 commit 7a8a4c3

File tree

1 file changed

+3
-3
lines changed

1 file changed

+3
-3
lines changed

packages/mongodb-memory-server-core/src/util/MongoBinaryDownloadUrl.ts

Lines changed: 3 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -34,9 +34,6 @@ export class MongoBinaryDownloadUrl {
3434
* Calls all the necessary functions to determine the URL
3535
*/
3636
async getDownloadUrl(): Promise<string> {
37-
const archive = await this.getArchiveName();
38-
log(`Using "${archive}" as the Archive String`);
39-
4037
const downloadUrl = resolveConfig(ResolveConfigVariables.DOWNLOAD_URL);
4138

4239
if (downloadUrl) {
@@ -45,6 +42,9 @@ export class MongoBinaryDownloadUrl {
4542
return downloadUrl;
4643
}
4744

45+
const archive = await this.getArchiveName();
46+
log(`Using "${archive}" as the Archive String`);
47+
4848
const mirror =
4949
resolveConfig(ResolveConfigVariables.DOWNLOAD_MIRROR) ?? 'https://fastdl.mongodb.org';
5050
log(`Using "${mirror}" as the mirror`);

0 commit comments

Comments
 (0)