Skip to content

Commit

Permalink
Initialize dependencies map even if there are no dependencies
Browse files Browse the repository at this point in the history
Signed-off-by: Alper Rifat Ulucinar <[email protected]>
  • Loading branch information
ulucinar committed Aug 5, 2022
1 parent 3fa8995 commit e6bc41d
Showing 1 changed file with 3 additions and 0 deletions.
3 changes: 3 additions & 0 deletions pkg/registry/resource.go
Original file line number Diff line number Diff line change
Expand Up @@ -83,6 +83,9 @@ func NewProviderMetadataFromFile(providerMetadata []byte) (*ProviderMetadata, er
return nil, errors.Wrapf(err, "cannot pave example manifest JSON: %s", re.Manifest)
}
rm.Examples[j] = re
if rm.Examples[j].Dependencies == nil {
rm.Examples[j].Dependencies = make(map[string]string)
}
}
metadata.Resources[name] = rm
}
Expand Down

0 comments on commit e6bc41d

Please sign in to comment.