Apply CLI overrides after typed decoding
This commit is contained in:
@@ -167,7 +167,7 @@ func assembleLayeredInput[T any](request loadRequest[T], input assembledInput, a
|
||||
}
|
||||
}
|
||||
}
|
||||
if assembly == nil && (activeOverlay(request.overlay) || len(request.overrides) != 0) {
|
||||
if assembly == nil && activeOverlay(request.overlay) {
|
||||
composition, _ := compositionForInput(assembledInput{})
|
||||
assembly = newAssemblyAccumulator(composition)
|
||||
}
|
||||
@@ -193,13 +193,6 @@ func assembleLayeredInput[T any](request loadRequest[T], input assembledInput, a
|
||||
}
|
||||
mergeResourceContexts(&input.contexts, contexts)
|
||||
}
|
||||
if len(request.overrides) != 0 {
|
||||
var diagnostics []Diagnostic
|
||||
input.sources, diagnostics = assembly.applyOverrides(input.sources, request.overrides, request.protectionVersion(), defaultImportLimits())
|
||||
if len(diagnostics) != 0 {
|
||||
return input, diagnostics
|
||||
}
|
||||
}
|
||||
input.composition = assembly.current
|
||||
input.document = assembly.current.root
|
||||
return input, nil
|
||||
|
||||
Reference in New Issue
Block a user