Skip to content

Commit

Permalink
Switch to less intense main moudle detection
Browse files Browse the repository at this point in the history
  • Loading branch information
f1yn committed Jan 20, 2024
1 parent 6cef002 commit 6b9f1be
Showing 1 changed file with 1 addition and 1 deletion.
2 changes: 1 addition & 1 deletion core/runtime.ts
Original file line number Diff line number Diff line change
Expand Up @@ -131,7 +131,7 @@ export function createRuntimeScope(options: RuntimeOptions = {}) {
}

// Detect if we are a main module (running in podman)
if (Deno.mainModule.endsWith('core/runtime.ts')) {
if (import.meta.main) {
// autostart execution if that's the case,otherwise assume we are headless and/or in-testing
createRuntimeScope().start();
}

0 comments on commit 6b9f1be

Please sign in to comment.