mirror of
https://github.com/gohugoio/hugo.git
synced 2025-08-13 20:24:00 +02:00
js/esbuild: Batch: Avoid nil Instances slice
Ranging over a nil slice in Go works great, but is a hassle onced passed to JS.
This commit is contained in:
@@ -506,8 +506,9 @@ func (b *batcher) doBuild(ctx context.Context) (*Package, error) {
|
||||
})
|
||||
|
||||
bt := scriptBatchTemplateContext{
|
||||
opts: vv,
|
||||
Import: impPath,
|
||||
opts: vv,
|
||||
Import: impPath,
|
||||
Instances: []scriptInstanceBatchTemplateContext{},
|
||||
}
|
||||
state.importResource.Set(bt.Import, vv.Compiled().Resource)
|
||||
predicate := func(k instanceID) bool {
|
||||
|
Reference in New Issue
Block a user