Skip to content

Commit e8b7cd9

Browse files
santoshyadavdevmgechev
authored andcommitted
fix(@schematics/angular): webworker snippet should not generate to module
Fixes #14467
1 parent a7f2346 commit e8b7cd9

File tree

1 file changed

+4
-2
lines changed
  • packages/schematics/angular/web-worker

1 file changed

+4
-2
lines changed

packages/schematics/angular/web-worker/index.ts

Lines changed: 4 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -63,8 +63,10 @@ function addSnippet(options: WebWorkerOptions): Rule {
6363
}
6464

6565
const siblingModules = host.getDir(options.path).subfiles
66-
// Find all files that start with the same name, are ts files, and aren't spec files.
67-
.filter(f => f.startsWith(options.name) && f.endsWith('.ts') && !f.endsWith('spec.ts'))
66+
// Find all files that start with the same name, are ts files,
67+
// and aren't spec or module files.
68+
.filter(f => f.startsWith(options.name) && f.endsWith('.ts')
69+
&& !f.endsWith('spec.ts') && !f.endsWith('-.module.ts'))
6870
// Sort alphabetically for consistency.
6971
.sort();
7072

0 commit comments

Comments
 (0)