message: Convert autoStart into an async function
diff: @@ -546,15 +546,16 @@ export class OmniSharpServer {
  }
  }
  - public autoStart(preferredPath: string): Thenable<void> {
  + public async autoStart(preferredPath: string): Promise<void> {
  const options = this.optionProvider.GetLatestOptions();
  - return findLaunchTargets(options).then(async launchTargets => {
  + const launchTargets = await findLaunchTargets(options);
  +
  // If there aren't any potential launch targets, we create file watcher and try to
  // start the server again once a *.sln, *.slnf, *.csproj, project.json, CSX or Cake file is created.
  if (launchTargets.length === 0) {
  - return new Promise<void>((resolve, reject) => {
  + await new Promise<void>((resolve, reject) => {
  // 1st watch for files
  - let watcher = this.vscode.workspace.createFileSystemWatcher('{**/*.sln,**/*.slnf,**/*.csproj,**/project.json,**/*.csx,**/*.cake}',
  + const watcher = this.vscode.workspace.createFileSystemWatcher('{**/*.sln,**/*.slnf,**/*.csproj,**/project.json,**/*.csx,**/*.cake}',
  /*ignoreCreateEvents*/ false,
  /*ignoreChangeEvents*/ true,
  /*ignoreDeleteEvents*/ true);
  @@ -563,10 +564,10 @@ export class OmniSharpServer {
  watcher.dispose();
  resolve();
  });
  - }).then(() => {
  + });
  +
  // 2nd try again
  return this.autoStart(preferredPath);
  - });
  }
  else if (launchTargets.length === 1) {
  // If there's only one target, just start
  @@ -583,7 +584,7 @@ export class OmniSharpServer {
  // If there's more than one launch target, we start the server if one of the targets
  // matches the preferred path.
  if (preferredPath.length > 0) {
  - const preferredLaunchTarget = launchTargets.find((a) => a.target === preferredPath);
  + const preferredLaunchTarget = launchTargets.find((a_1) => a_1.target === preferredPath);
  if (preferredLaunchTarget) {
  return this.restart(preferredLaunchTarget);
  }
  @@ -605,8 +606,7 @@ export class OmniSharpServer {
  // Otherwise, we fire the "MultipleLaunchTargets" event,
  // which is handled in status.ts to display the launch target selector.
  this._fireEvent(Events.MultipleLaunchTargets, launchTargets);
  - return showProjectSelector(this, launchTargets);
  - });
  + return await showProjectSelector(this, launchTargets);
  }
  // --- requests et al
  