about summary refs log tree commit diff
path: root/editors/code/src
diff options
context:
space:
mode:
authorMatthias Einwag <matthias.einwag@live.com>2020-09-23 08:27:25 -0700
committerMatthias Einwag <matthias.einwag@live.com>2020-09-23 08:27:25 -0700
commitdf4d59512e496ff010c8710e8ea8e2db4a7f4822 (patch)
treea6416fd927a9294d05743d47dce3c3413e1de6c7 /editors/code/src
parentd38f759c631039d11cb490692b5e07b00324ff10 (diff)
downloadrust-df4d59512e496ff010c8710e8ea8e2db4a7f4822.tar.gz
rust-df4d59512e496ff010c8710e8ea8e2db4a7f4822.zip
Remane function
Diffstat (limited to 'editors/code/src')
-rw-r--r--editors/code/src/main.ts10
1 files changed, 5 insertions, 5 deletions
diff --git a/editors/code/src/main.ts b/editors/code/src/main.ts
index 0ee5280cc02..f865639a14d 100644
--- a/editors/code/src/main.ts
+++ b/editors/code/src/main.ts
@@ -177,7 +177,7 @@ async function bootstrapExtension(config: Config, state: PersistentState): Promi
         if (!shouldCheckForNewNightly) return;
     }
 
-    const release = await performDownloadWithRetryDialog(state, async () => {
+    const release = await downloadWithRetryDialog(state, async () => {
         return await fetchRelease("nightly", state.githubToken);
     }).catch((e) => {
         log.error(e);
@@ -199,7 +199,7 @@ async function bootstrapExtension(config: Config, state: PersistentState): Promi
 
     const dest = path.join(config.globalStoragePath, "rust-analyzer.vsix");
 
-    await performDownloadWithRetryDialog(state, async () => {
+    await downloadWithRetryDialog(state, async () => {
         // Unlinking the exe file before moving new one on its place should prevent ETXTBSY error.
         await fs.unlink(dest).catch(err => {
             if (err.code !== "ENOENT") throw err;
@@ -323,13 +323,13 @@ async function getServer(config: Config, state: PersistentState): Promise<string
     }
 
     const releaseTag = config.package.releaseTag;
-    const release = await performDownloadWithRetryDialog(state, async () => {
+    const release = await downloadWithRetryDialog(state, async () => {
         return await fetchRelease(releaseTag, state.githubToken);
     });
     const artifact = release.assets.find(artifact => artifact.name === `rust-analyzer-${platform}.gz`);
     assert(!!artifact, `Bad release: ${JSON.stringify(release)}`);
 
-    await performDownloadWithRetryDialog(state, async () => {
+    await downloadWithRetryDialog(state, async () => {
         // Unlinking the exe file before moving new one on its place should prevent ETXTBSY error.
         await fs.unlink(dest).catch(err => {
             if (err.code !== "ENOENT") throw err;
@@ -353,7 +353,7 @@ async function getServer(config: Config, state: PersistentState): Promise<string
     return dest;
 }
 
-async function performDownloadWithRetryDialog<T>(state: PersistentState, downloadFunc: () => Promise<T>): Promise<T> {
+async function downloadWithRetryDialog<T>(state: PersistentState, downloadFunc: () => Promise<T>): Promise<T> {
     while (true) {
         try {
             return await downloadFunc();