Skip to content

Commit 14ef260

Browse files
committed
fix: add javascript glob to defaults
1 parent cb72c69 commit 14ef260

File tree

2 files changed

+4
-1
lines changed

2 files changed

+4
-1
lines changed

pkg/stack/options.go

Lines changed: 3 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -40,6 +40,9 @@ func EnsureRuntimeDefaults() bool {
4040
"ts": {
4141
"functionglob": "functions/*.ts",
4242
},
43+
"js": {
44+
"functionglob": "functions/*.js",
45+
},
4346
"go": {
4447
"functionglob": "functions/*/*.go",
4548
},

pkg/stack/options_test.go

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -128,7 +128,7 @@ func TestEnsureRuntimeDefaults(t *testing.T) {
128128
if got := EnsureRuntimeDefaults(); got != want {
129129
t.Errorf("EnsureRuntimeDefaults() = %v, want %v", got, want)
130130
}
131-
expectGlobs := []string{"functions/*/*.go", "functions/*.ts"}
131+
expectGlobs := []string{"functions/*/*.go", "functions/*.ts", "functions/*.js"}
132132
sort.SliceStable(expectGlobs, func(i, j int) bool {
133133
return expectGlobs[i] < expectGlobs[j]
134134
})

0 commit comments

Comments
 (0)