Preserve defaulted prompt input inspection metadata
This commit is contained in:
@@ -176,6 +176,9 @@ func Capture(input *settings.Settings, view configkit.Inspection, diagnostics []
|
||||
for i := range entry.Inputs {
|
||||
path := resources.bases.prompts.Index(index).Key("inputs").Index(i)
|
||||
presence[i] = promptInputPresence{required: finalFieldState(metadata, path.Key("required")), contentType: finalFieldState(metadata, path.Key("content_type")), description: finalFieldState(metadata, path.Key("description"))}
|
||||
if entry.Inputs[i].Required {
|
||||
presence[i].required = fieldValue
|
||||
}
|
||||
}
|
||||
state.promptMetadata[indexedResourceID(resources.namespace, entry.ID)] = presence
|
||||
}
|
||||
|
||||
Reference in New Issue
Block a user