target: ensure that each used target has NewXXXTargetResult defined
Ensure that `UnmarshalTargetResultOptions()` is called only when there are any options to unmarshal in the JSON object. Since results of some Targets don't have any options defined, mark `TargetResult.Options` as optional in the JSON tag.
This commit is contained in:
parent
6f13db5b92
commit
93fd5e3821
5 changed files with 135 additions and 5 deletions
|
|
@ -24,3 +24,7 @@ func (AzureTargetOptions) isTargetOptions() {}
|
|||
func NewAzureTarget(options *AzureTargetOptions) *Target {
|
||||
return newTarget(TargetNameAzure, options)
|
||||
}
|
||||
|
||||
func NewAzureTargetResult() *TargetResult {
|
||||
return newTargetResult(TargetNameAzure, nil)
|
||||
}
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue