Skip to content

Commit 4a2997a

Browse files
fix looping files
1 parent 3991bef commit 4a2997a

File tree

1 file changed

+10
-13
lines changed
  • packages/app/src/app/overmind/effects/vscode

1 file changed

+10
-13
lines changed

packages/app/src/app/overmind/effects/vscode/index.ts

Lines changed: 10 additions & 13 deletions
Original file line numberDiff line numberDiff line change
@@ -303,19 +303,16 @@ export class VSCodeEffect {
303303
public async openModule(module: Module) {
304304
await this.initialized;
305305

306-
// We open this on the next tick to allow a UI update to occur first
307-
setTimeout(async () => {
308-
try {
309-
const model = await this.modelsHandler.changeModule(module);
310-
311-
this.lint(module.title, model);
312-
} catch (error) {
313-
// We might try to open a module that is not actually opened in the editor,
314-
// but the configuration wizard.. currently this throws an error as there
315-
// is really no good way to identify when it happen. This needs to be
316-
// improved in next version
317-
}
318-
});
306+
try {
307+
const model = await this.modelsHandler.changeModule(module);
308+
309+
this.lint(module.title, model);
310+
} catch (error) {
311+
// We might try to open a module that is not actually opened in the editor,
312+
// but the configuration wizard.. currently this throws an error as there
313+
// is really no good way to identify when it happen. This needs to be
314+
// improved in next version
315+
}
319316
}
320317

321318
setErrors = (errors: ModuleError[]) => {

0 commit comments

Comments
 (0)